On Dec 13, 2012, at 14:35, Marcel Laverdet <mar...@laverdet.com> wrote:

>> var myobj = require( the-file );
>> eval( 'myobjs.' + file-name = myobj;');
> 
> How has no one commented on the fact that you're doing numeric arithmetic on 
> a bunch of strings? All this is going to do is give you a parse error, and 
> when you fix that you're just doing require(NaN).

I'm not sure exactly what the original intent was, since there's already a 
parse error due to an odd number of quote marks, but I assumed the "+" operator 
was being used for string concatenation (not numeric arithmetic).

-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to nodejs@googlegroups.com
To unsubscribe from this group, send email to
nodejs+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

Reply via email to