OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Flags: --harmony-async-await --allow-natives-syntax --expose-debug-as debug | 5 // Flags: --harmony-async-await |
6 | 6 |
7 // Get the Debug object exposed from the debug context global object. | |
8 Debug = debug.Debug | 7 Debug = debug.Debug |
9 | 8 |
10 listenerComplete = false; | 9 listenerComplete = false; |
11 breakPointCount = 0; | 10 breakPointCount = 0; |
12 | 11 |
13 async function f() { | 12 async function f() { |
14 await (async function() { var a = "a"; await 1; debugger; })(); | 13 await (async function() { var a = "a"; await 1; debugger; })(); |
15 | 14 |
16 var b = "b"; | 15 var b = "b"; |
17 | 16 |
(...skipping 13 matching lines...) Expand all Loading... |
31 assertEquals("c", exec_state.frame(2).evaluate("c")); | 30 assertEquals("c", exec_state.frame(2).evaluate("c")); |
32 } catch (e) { | 31 } catch (e) { |
33 exception = e; | 32 exception = e; |
34 }; | 33 }; |
35 }; | 34 }; |
36 | 35 |
37 Debug.setListener(listener); | 36 Debug.setListener(listener); |
38 | 37 |
39 var c = "c"; | 38 var c = "c"; |
40 f(); | 39 f(); |
OLD | NEW |