mirror of
https://github.com/nodejs/node.git
synced 2025-05-15 16:01:52 +00:00

PR-URL: https://github.com/nodejs/node/pull/14730 Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl> Reviewed-By: Ali Ijaz Sheikh <ofrobots@google.com> Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
23 lines
633 B
JavaScript
23 lines
633 B
JavaScript
// Copyright 2017 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: --allow-natives-syntax --validate-asm
|
|
|
|
// Compilation limits for wasm are not enforced for asm->wasm.
|
|
%SetWasmCompileControls(0, false);
|
|
|
|
function AsmModule() {
|
|
"use asm";
|
|
function xxx() { return 43; }
|
|
function yyy() { return 43; }
|
|
function zzz() { return 43; }
|
|
function main() { return 43; }
|
|
|
|
return {main: main};
|
|
}
|
|
|
|
assertEquals(43, AsmModule(
|
|
undefined, undefined, new ArrayBuffer(1024)).main());
|
|
assertTrue(%IsAsmWasmCode(AsmModule));
|