LGTM.
http://codereview.chromium.org/6386014/diff/1/src/scanner-base.cc File src/scanner-base.cc (right): http://codereview.chromium.org/6386014/diff/1/src/scanner-base.cc#newcode100 src/scanner-base.cc:100: // ECMA-262. Other JS VMs support them. Add comment here (or, preferably, at the declaration) saying that it also accepts the decimal escape "\0". http://codereview.chromium.org/6386014/diff/1/src/scanner-base.cc#newcode112 src/scanner-base.cc:112: // Allow \0 only. Rest are octal escapes, illegal in strict mode. We "allow" everything (we don't reject anything here), it's just '\0' that isn't really an octal escape. Make comment something like "Anything except '\0' is an ocatal escape, which are illegal in strict mode. Remember position to be able to give a better error message.". http://codereview.chromium.org/6386014/diff/1/test/mjsunit/strict-mode.js File test/mjsunit/strict-mode.js (right): http://codereview.chromium.org/6386014/diff/1/test/mjsunit/strict-mode.js#newcode158 test/mjsunit/strict-mode.js:158: If the preparser marks this function as lazy (which it will), the body won't be parsed by the parser at all. In that case, even if there was a strict-mode syntax error, I'm not sure it would be thrown. You need to call the function to be sure that it's parsed. (We should probably add checks to the preparser too, to ensure that we make it an early error). http://codereview.chromium.org/6386014/ -- v8-dev mailing list [email protected] http://groups.google.com/group/v8-dev
