v8/test/mjsunit/es6/regress/regress-3280.js
wingo@igalia.com a76fe0a2cf Enable ES6 generators
R=rossberg@chromium.org

BUG=v8:2355
LOG=Y

Review URL: https://codereview.chromium.org/573963003

git-svn-id: https://v8.googlecode.com/svn/branches/bleeding_edge@23974 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
2014-09-16 12:30:39 +00:00

26 lines
579 B
JavaScript

// Copyright 2014 the V8 project authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// Flags: --expose-debug-as debug
var Debug = debug.Debug;
var listener_called;
function listener(event, exec_state, event_data, data) {
if (event == Debug.DebugEvent.Break) {
listener_called = true;
exec_state.frame().allScopes();
}
}
Debug.setListener(listener);
function *generator_local_2(a) {
debugger;
}
generator_local_2(1).next();
assertTrue(listener_called, "listener not called");