2017-08-01 11:36:44 -05:00
|
|
|
// Copyright 2017 the V8 project authors. All rights reserved.
|
2017-05-02 10:50:00 +02:00
|
|
|
// Use of this source code is governed by a BSD-style license that can be
|
|
|
|
// found in the LICENSE file.
|
|
|
|
|
2021-08-29 14:20:49 +02:00
|
|
|
d8.file.execute("test/mjsunit/wasm/wasm-module-builder.js");
|
2017-05-02 10:50:00 +02:00
|
|
|
|
|
|
|
(function() {
|
|
|
|
"use asm";
|
|
|
|
var builder = new WasmModuleBuilder();
|
2023-10-05 08:46:07 +02:00
|
|
|
builder.addMemory(0, 5);
|
2017-05-02 10:50:00 +02:00
|
|
|
builder.addFunction("regression_699485", kSig_i_v)
|
|
|
|
.addBody([
|
|
|
|
kExprI32Const, 0x04,
|
|
|
|
kExprNop,
|
2019-03-12 09:01:49 +01:00
|
|
|
kExprMemoryGrow, 0x00,
|
2017-05-02 10:50:00 +02:00
|
|
|
]).exportFunc();
|
|
|
|
let module = builder.instantiate();
|
|
|
|
assertEquals(0, module.exports.regression_699485());
|
|
|
|
})();
|