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

Unified Diff: test/debugger/debug/es8/async-function-debug-evaluate.js

Issue 2898163002: Make non-Module generators only context allocate parameters. (Closed)
Patch Set: Rebase Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: test/debugger/debug/es8/async-function-debug-evaluate.js
diff --git a/test/debugger/debug/es8/async-function-debug-evaluate.js b/test/debugger/debug/es8/async-function-debug-evaluate.js
index a635482f51e18cd90c7df2eac84c46022feadede..c1fe532231558821a768a2da140fd19d22abb877 100644
--- a/test/debugger/debug/es8/async-function-debug-evaluate.js
+++ b/test/debugger/debug/es8/async-function-debug-evaluate.js
@@ -2,6 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
+// Flags: --noalways-opt
+
var Debug = debug.Debug;
var breakPointCount = 0;
@@ -12,10 +14,9 @@ function listener(event, exec_state, event_data, data) {
if (breakPointCount === 1) {
assertEquals(
"inner", exec_state.frame(0).evaluate("inner").value());
- assertThrows(() => exec_state.frame(0).evaluate("letInner").value(),
- ReferenceError);
- assertThrows(() => exec_state.frame(0).evaluate("constInner").value(),
- ReferenceError);
+ // Variables in TDZ have 'undefined' as their values.
+ assertEquals(undefined, exec_state.frame(0).evaluate("letInner").value());
+ assertEquals(undefined, exec_state.frame(0).evaluate("constInner").value());
assertEquals("outer", exec_state.frame(0).evaluate("outer").value());
assertEquals(
@@ -29,16 +30,15 @@ function listener(event, exec_state, event_data, data) {
assertEquals(
"let outer", exec_state.frame(1).evaluate("letOuter").value());
- assertThrows(() => exec_state.frame(0).evaluate("withVar").value(),
- ReferenceError);
+ // Variables in TDZ have 'undefined' as their values.
+ assertEquals(undefined, exec_state.frame(0).evaluate("withVar").value());
} else if (breakPointCount === 2) {
assertEquals(
"inner", exec_state.frame(0).evaluate("inner").value());
- assertThrows(() => exec_state.frame(0).evaluate("letInner").value(),
- ReferenceError);
- assertThrows(() => exec_state.frame(0).evaluate("constInner").value(),
- ReferenceError);
+ // Variables in TDZ have 'undefined' as their values.
+ assertEquals(undefined, exec_state.frame(0).evaluate("letInner").value());
+ assertEquals(undefined, exec_state.frame(0).evaluate("constInner").value());
assertEquals(57, exec_state.frame(0).evaluate("x").value());
assertEquals(100, exec_state.frame(0).evaluate("y").value());
@@ -70,8 +70,8 @@ function listener(event, exec_state, event_data, data) {
"Error",
exec_state.frame(0).evaluate("error.constructor.name").value());
assertEquals("floof", exec_state.frame(0).evaluate("bun").value());
- assertThrows(() => exec_state.frame(0).evaluate("cow").value(),
- ReferenceError);
+ // Variables in TDZ have 'undefined' as their values.
+ assertEquals(undefined, exec_state.frame(0).evaluate("cow").value())
assertEquals("outer", exec_state.frame(0).evaluate("outer").value());
assertEquals(
« no previous file with comments | « test/debugger/debug/debug-scopes-suspended-generators.js ('k') | test/debugger/debug/es8/async-function-debug-scopes.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698