• adamk's avatar
    [es6] Self-assignment in a default parameter initializer should throw · b6e9f625
    adamk authored
    The first bug was that there are two different "initialization positions"
    passed into PatternRewriter::DeclareAndInitializeVariables, and we weren't
    setting them all properly for this case.
    
    After further code review, it became clear that we weren't even recording
    the correct position (the end of the initializer expression).
    
    The combination of those two bugs caused the hole check elimination code
    in full-codegen to skip emitting a hole check.
    
    This patch takes care of both of those things. A follow-up will try
    to reduce the number of "initializer positions" we track in the
    variable declaration code.
    
    R=littledan@chromium.org
    BUG=v8:4568
    LOG=n
    
    Review URL: https://codereview.chromium.org/1468143004
    
    Cr-Commit-Position: refs/heads/master@{#32237}
    b6e9f625
Name
Last commit
Last update
..
benchmarks Loading commit data...
cctest Loading commit data...
intl Loading commit data...
js-perf-test Loading commit data...
memory Loading commit data...
message Loading commit data...
mjsunit Loading commit data...
mozilla Loading commit data...
preparser Loading commit data...
promises-aplus Loading commit data...
simdjs Loading commit data...
test262 Loading commit data...
unittests Loading commit data...
webkit Loading commit data...
bot_default.gyp Loading commit data...
bot_default.isolate Loading commit data...
default.gyp Loading commit data...
default.isolate Loading commit data...
optimize_for_size.gyp Loading commit data...
optimize_for_size.isolate Loading commit data...