• Mathias Bynens's avatar
    [inspector] Improve regular expression printing · 50be01b2
    Mathias Bynens authored
    Prior to this patch, `new RegExp('a/b')` logs the following in
    the DevTools Console:
    
        /a/b/
    
    This is syntactically invalid.
    
    This patch fixes this while simplifying regular expression printing
    in general by leveraging `RegExp#toString`, instead of duplicating
    the logic on the inspector side. This is possible thanks to the recent
    work on making `RegExp#toString` more robust (v8:1982).
    
    Bug: chromium:1202013, v8:1982
    Change-Id: I14ccc1892f4a99361ad170fea608ace630740991
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2848463
    Commit-Queue: Mathias Bynens <mathias@chromium.org>
    Reviewed-by: 's avatarYang Guo <yangguo@chromium.org>
    Cr-Commit-Position: refs/heads/master@{#74169}
    50be01b2
Name
Last commit
Last update
..
console Loading commit data...
counters Loading commit data...
cpu-profiler Loading commit data...
debugger Loading commit data...
heap-profiler Loading commit data...
regress Loading commit data...
runtime Loading commit data...
runtime-call-stats Loading commit data...
sessions Loading commit data...
type-profiler Loading commit data...
BUILD.gn Loading commit data...
DEPS Loading commit data...
DIR_METADATA Loading commit data...
OWNERS Loading commit data...
frontend-channel.h Loading commit data...
inspector-test.cc Loading commit data...
inspector.status Loading commit data...
isolate-data.cc Loading commit data...
isolate-data.h Loading commit data...
json-parse-expected.txt Loading commit data...
json-parse.js Loading commit data...
print-method-not-found-expected.txt Loading commit data...
print-method-not-found.js Loading commit data...
protocol-test.js Loading commit data...
task-runner.cc Loading commit data...
task-runner.h Loading commit data...
tasks.cc Loading commit data...
tasks.h Loading commit data...
testcfg.py Loading commit data...
utils.cc Loading commit data...
utils.h Loading commit data...
wasm-inspector-test.js Loading commit data...