http://codereview.chromium.org/115747/diff/1004/5
File src/d8.cc (right):

http://codereview.chromium.org/115747/diff/1004/5#newcode183
Line 183: if (args.Length() != 0) {
I would remove this check.  It's un-JavaScript-y to give errors on
unexpected number of arguments (Read above shouldn't do it either).

http://codereview.chromium.org/115747/diff/1004/5#newcode191
Line 191: if (line_buf[len - 1] == '\n') {
Instead of overwriting the '\n' you can just pass a shorter length to
String::New.

http://codereview.chromium.org/115747/diff/1004/5#newcode194
Line 194: return Handle<String>(String::New(line_buf));
String::New returns a handle, you don't have to wrap it explicitly.

http://codereview.chromium.org/115747

--~--~---------~--~----~------------~-------~--~----~
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev
-~----------~----~----~----~------~----~------~--~---

Reply via email to