cptn-decl.js (588B)
1 // Copyright (C) 2017 Apple Inc. All rights reserved. 2 // This code is governed by the BSD license found in the LICENSE file. 3 /*--- 4 esid: sec-async-function-definitions-runtime-semantics-evaluation 5 description: Async function declaration completion value is empty. 6 info: | 7 AsyncFunctionDeclaration : async [no LineTerminator here] function BindingIdentifier ( FormalParameters ) { AsyncFunctionBody } 8 9 1. Return NormalCompletion(empty). 10 ---*/ 11 12 assert.sameValue(eval('async function f() {}'), undefined); 13 assert.sameValue(eval('1; async function f() {}'), 1); 14 15 reportCompare(0, 0);