Revision control
Copy as Markdown
// Copyright (C) 2017 the V8 project authors. All rights reserved.
// This code is governed by the BSD license found in the LICENSE file.
/*---
desc: SingleNameBinding when value iteration was completed previously
template: default
info: |
13.3.3.6 Runtime Semantics: IteratorBindingInitialization
SingleNameBinding : BindingIdentifier Initializer_opt
[...]
3. If iteratorRecord.[[done]] is false, then
[...]
4. If iteratorRecord.[[done]] is true, let v be undefined.
[...]
7. Return InitializeReferencedBinding(lhs, v).
---*/
//- elems
[_, x]
//- vals
[]
//- body
assert.sameValue(x, undefined);