Commit 8143a3e0 authored by Manos Koukoutos's avatar Manos Koukoutos Committed by Commit Bot

[wasm-gc] Add test for disallowed packed globals

Bug: v8:7748
Change-Id: I6793133d7b05c3b8dbece80a51a7a6e5e250e8b1
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/2284482
Commit-Queue: Manos Koukoutos <manoskouk@chromium.org>
Reviewed-by: 's avatarJakob Kummerow <jkummerow@chromium.org>
Cr-Commit-Position: refs/heads/master@{#68717}
parent 3a50eae0
......@@ -2723,6 +2723,19 @@ TEST_F(WasmModuleVerifyTest, GcTypeIdsFunSigIllegalIndex) {
EXPECT_NOT_OK(result, "cannot build reference to function type index");
}
TEST_F(WasmModuleVerifyTest, IllegalPackedFields) {
WASM_FEATURE_SCOPE(gc);
WASM_FEATURE_SCOPE(typed_funcref);
WASM_FEATURE_SCOPE(reftypes);
static const byte data[] = {
SECTION(Global, ENTRY_COUNT(1), kLocalI16, 0, WASM_INIT_EXPR_I32V_1(13))};
ModuleResult result = DecodeModule(data, data + sizeof(data));
EXPECT_NOT_OK(result, "invalid value type");
}
#undef EXPECT_INIT_EXPR
#undef EXPECT_INIT_EXPR_FAIL
#undef WASM_INIT_EXPR_I32V_1
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment