• marja@chromium.org's avatar
    Tests and fixes for (pre)parse errors related to strict reserved words. · 443e645a
    marja@chromium.org authored
    This contains the following fixes:
    
    - We had strict_reserved_word and unexpected_strict_reserved, which one to use
    was totally mixed in Parser and PreParser. Removed strict_reserved_word.
    - When we saw a strict future reserved word when expecting something completely
    different (such as "(" in "function foo interface"), Parser reports unexpected
    identifier, whereas PreParser used to report unexpected strict reserved
    word. Fixed PreParser to report unexpected identifier too.
    - Unified parser and preparser error locations when the name of a function is a
    strict reserved word. Now both point to the name.
    
    BUG=3126
    LOG=N
    R=ulan@chromium.org
    
    Review URL: https://codereview.chromium.org/149253010
    
    git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@19067 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
    443e645a
parser.cc 189 KB