v8/test
Simon Zünd fbcc2e874d Introduce REPL mode
Design doc: bit.ly/v8-repl-mode

This CL adds a new REPL mode that can be used via
DebugEvaluate::GlobalREPL. REPL mode only implements re-declaration
of 'let' bindings at the moment. Example:

REPL Input 1: let x = 21;
REPL Input 2: let x = 42;

This would normally throw a SyntaxError, but works in REPL mode.

The implementation is done by:
  - Setting a 'repl mode' bit on {Script}, {ScopeInfo}, {ParseInfo}
    and script {Scope}.
  - Each global let declaration still gets a slot reserved in the
    respective {ScriptContext}.
  - When a new REPL mode {ScriptContext} is created, name clashes
    for let bindings are not reported as errors.
  - Declarations, loads and stores for global let in REPL mode are
    now "load/store global" instead of accessing their respective
    context slot directly. This causes a lookup in the ScriptContextTable
    where the found slot for each name is guaranteed to be the same
    (the first one).

Bug: chromium:1004193, chromium:1018158
Change-Id: Ia6ab526b9f696400dbb8bfb611a4d43606119a47
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1876061
Commit-Queue: Simon Zünd <szuend@chromium.org>
Reviewed-by: Ross McIlroy <rmcilroy@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Cr-Commit-Position: refs/heads/master@{#64793}
2019-11-06 09:17:04 +00:00
..
benchmarks Remove 'embedded_builtins' variant 2019-10-22 12:58:02 +00:00
cctest Revert "[hole-check-elimination] Simplest possible hole check elimination" 2019-11-05 22:22:54 +00:00
common [wasm] Rename {Get,Set}Global to Global{Get,Set} 2019-10-08 14:27:50 +00:00
debugger Introduce REPL mode 2019-11-06 09:17:04 +00:00
fuzzer Remove 'embedded_builtins' variant 2019-10-22 12:58:02 +00:00
inspector [DevTools] Implemented DevTools protocol API to retrieve V8 RunTime Call Stats. 2019-11-05 18:59:24 +00:00
intl Roll to ICU 65.1 2019-10-31 17:13:46 +00:00
js-perf-test [js-perf-tests] Adds performance tests for BigInt subtraction 2019-10-22 13:32:09 +00:00
memory [owners] Remove redundant OWNERS files in test/ 2019-06-24 12:44:32 +00:00
message V8 Wasm locations should always be based on byte offsets 2019-11-05 14:53:45 +00:00
mjsunit Revert "[hole-check-elimination] Simplest possible hole check elimination" 2019-11-05 22:22:54 +00:00
mkgrokdump [heap] Enable Verify for RO_SPACE when it is shared 2019-11-04 09:55:45 +00:00
mozilla Un-marking tests that were marked SLOW due to TNodification 2019-11-04 13:30:30 +00:00
preparser Fix an error caused by a bug in Python < 2.7.9 2019-11-04 13:42:10 +00:00
test262 Fix variant sorting in locale by rolling ICU 2019-11-04 10:25:30 +00:00
torque [torque] fix formatting of union types 2019-10-24 10:05:25 +00:00
unittests Preserve feedback and speculation mode for JSCall 2019-11-04 13:22:50 +00:00
wasm-api-tests Remove 'embedded_builtins' variant 2019-10-22 12:58:02 +00:00
wasm-js [wasm] update spec tests 2019-10-31 10:09:46 +00:00
wasm-spec-tests [wasm] update spec tests 2019-10-31 10:09:46 +00:00
webkit Remove 'embedded_builtins' variant 2019-10-22 12:58:02 +00:00
BUILD.gn Remove cctest dependency from v8_perf group 2019-10-31 14:09:29 +00:00
OWNERS Use relative paths to OWNERS files 2019-08-12 13:52:52 +00:00