c249669c58
Before dropping a value we should validate that there is indeed a value on the stack. R=jkummerow@chromium.org Bug: chromium:1184964 Change-Id: Iec3ac061df2545717749e664b10c383765d67c9d Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2739588 Reviewed-by: Jakob Kummerow <jkummerow@chromium.org> Commit-Queue: Clemens Backes <clemensb@chromium.org> Cr-Commit-Position: refs/heads/master@{#73263}
12 lines
423 B
JavaScript
12 lines
423 B
JavaScript
// Copyright 2021 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: --wasm-lazy-compilation
|
|
|
|
load('test/mjsunit/wasm/wasm-module-builder.js');
|
|
|
|
const builder = new WasmModuleBuilder();
|
|
builder.addFunction('foo', kSig_v_v).addBody([kExprDrop]);
|
|
assertThrows(() => builder.instantiate(), WebAssembly.CompileError);
|