Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.javascript > #19074

Re: Scoping issue I think

Message-ID <2182953.ZuCaxiteiE@PointedEars.de> (permalink)
From Thomas 'PointedEars' Lahn <PointedEars@web.de>
Organization PointedEars Software (PES)
Date 2013-03-31 18:26 +0200
Subject Re: Scoping issue I think
Newsgroups comp.lang.javascript
References <f52678fa-29a5-4b1c-b125-9d3e5ec2eddb@googlegroups.com> <d6f9c4ba-f3ef-4baa-a56c-65e9a64b6598@googlegroups.com>

Show all headers | View raw


patrickmartin145@gmail.com wrote:

> [100+ lines of quote]

You can't be serious.

<http://jibbering.com/faq/#posting>
<http://PointedEars.de/faq#posting>

[Googlodyte-introduced, pointless intermediate empty lines removed]
>> […]
>>   getChildren(connections, depth)
>>   {
>>     //dex.console.log("connections:", connections, "depth="+depth);
>> 
>>     var kids = [];
>> 
>>     if ( typeof connections == 'undefined')
>>     {
>>       return kids;
>>     }
>> 
>>     for (var cname in connections)
>>     {
>>       //dex.console.log("CNAME", cname);
>> 
>>       kids.push(
>>       {
>>         "name" : cname,
>>         "category" : csv.header[depth],
>>         "children" : dex.csv.getChildren(connections[cname], depth + 1)
>>       });
>>     }
>> 
>>     return kids;
>>   }
>> 
>>   return json;
>> };
>> 
>> […]
> 
> It turns out, the code was working just fine.

Doubtful.  Have you read my other answer?  If yes, have you understood it?

> There was another routine which was altering the data in the background
> before it got back to the console.

I would like to know the ECMAScript implementation with which this code 
“works just fine”; that is, where the Function object referred to by 
“getChildren” is _not_ [[Call]]ed when execution reaches the line 
“getChildren(connections, depth)” followed by “{…}”.

-- 
PointedEars

Twitter: @PointedEars2
Please do not Cc: me. / Bitte keine Kopien per E-Mail.

Back to comp.lang.javascript | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

Scoping issue I think patrickmartin145@gmail.com - 2013-03-29 15:06 -0700
  Re: Scoping issue I think patrickmartin145@gmail.com - 2013-03-29 15:11 -0700
  Re: Scoping issue I think patrickmartin145@gmail.com - 2013-03-29 15:29 -0700
  Re: Scoping issue I think Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-03-29 23:43 +0100
  Re: Scoping issue I think patrickmartin145@gmail.com - 2013-03-31 09:13 -0700
    Re: Scoping issue I think Thomas 'PointedEars' Lahn <PointedEars@web.de> - 2013-03-31 18:26 +0200

csiph-web