Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(202)

Side by Side Diff: test/mjsunit/regress/regress-crbug-621361.js

Issue 2185913003: [debugger] Scope iterator should not visit inner function literals. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/debug/debug-scopes.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2016 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Flags: --expose-debug-as debug
6
7 var Debug = debug.Debug;
8 var steps = 0;
9 var exception = null;
10
11 function listener(event, execState, eventData, data) {
12 if (event != Debug.DebugEvent.Break) return;
13 try {
14 assertEquals([ debug.ScopeType.Local,
15 debug.ScopeType.Script,
16 debug.ScopeType.Global],
17 execState.frame().allScopes().map(s => s.scopeType()));
18 var x_value = execState.frame().evaluate("x").value();
19 if (steps < 2) {
20 assertEquals(undefined, x_value);
21 execState.prepareStep(Debug.StepAction.StepIn);
22 } else {
23 assertEquals("l => l", x_value.toString());
24 }
25 steps++;
26 } catch (e) {
27 exception = e;
28 }
29 }
30
31 Debug.setListener(listener);
32
33 (function() {
34 debugger;
35 var x = l => l;
36 })();
37
38 Debug.setListener(null);
39 assertNull(exception);
40 assertEquals(3, steps);
OLDNEW
« no previous file with comments | « src/debug/debug-scopes.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698