From 45cf6a4f99d00f1da66805d97b3005e1985bd030 Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Wed, 15 Jul 2020 09:22:22 -0500 Subject: [PATCH] Update walrus and wasmparser deps (#2234) * Update walrus and wasmparser deps Gets some bug fixes and encoding updates for reference types * Update test expectations * Fix test for node 14.5 --- crates/cli-support/Cargo.toml | 6 +++--- crates/cli/Cargo.toml | 7 +++---- crates/externref-xform/Cargo.toml | 4 ++-- crates/externref-xform/tests/anyref-param.wat | 2 +- crates/externref-xform/tests/mixed-export.wat | 2 +- crates/externref-xform/tests/table-grow-intrinsic.wat | 2 +- crates/externref-xform/tests/table-set-null-intrinsic.wat | 2 +- crates/multi-value-xform/Cargo.toml | 4 ++-- crates/threads-xform/Cargo.toml | 2 +- crates/wasm-conventions/Cargo.toml | 2 +- crates/wasm-interpreter/Cargo.toml | 2 +- tests/wasm/classes.js | 2 +- 12 files changed, 18 insertions(+), 19 deletions(-) diff --git a/crates/cli-support/Cargo.toml b/crates/cli-support/Cargo.toml index 721406d07..d870036eb 100644 --- a/crates/cli-support/Cargo.toml +++ b/crates/cli-support/Cargo.toml @@ -18,13 +18,13 @@ log = "0.4" rustc-demangle = "0.1.13" serde_json = "1.0" tempfile = "3.0" -walrus = "0.17.0" +walrus = "0.18.0" wasm-bindgen-externref-xform = { path = '../externref-xform', version = '=0.2.64' } wasm-bindgen-multi-value-xform = { path = '../multi-value-xform', version = '=0.2.64' } wasm-bindgen-shared = { path = "../shared", version = '=0.2.64' } wasm-bindgen-threads-xform = { path = '../threads-xform', version = '=0.2.64' } wasm-bindgen-wasm-conventions = { path = '../wasm-conventions', version = '=0.2.64' } wasm-bindgen-wasm-interpreter = { path = "../wasm-interpreter", version = '=0.2.64' } -wit-text = "0.7.0" -wit-walrus = "0.4.0" +wit-text = "0.8.0" +wit-walrus = "0.5.0" wit-validator = "0.2.0" diff --git a/crates/cli/Cargo.toml b/crates/cli/Cargo.toml index ec5878017..b41041a75 100644 --- a/crates/cli/Cargo.toml +++ b/crates/cli/Cargo.toml @@ -24,7 +24,7 @@ rouille = { version = "3.0.0", default-features = false } serde = { version = "1.0", features = ['derive'] } serde_derive = "1.0" serde_json = "1.0" -walrus = { version = "0.17.0", features = ['parallel'] } +walrus = { version = "0.18.0", features = ['parallel'] } wasm-bindgen-cli-support = { path = "../cli-support", version = "=0.2.64" } wasm-bindgen-shared = { path = "../shared", version = "=0.2.64" } @@ -34,11 +34,10 @@ diff = "0.1" predicates = "1.0.0" rayon = "1.0" tempfile = "3.0" -walrus = "0.17" wit-printer = "0.2" -wit-text = "0.7" +wit-text = "0.8" wit-validator = "0.2" -wit-walrus = "0.4" +wit-walrus = "0.5" [[test]] name = "reference" diff --git a/crates/externref-xform/Cargo.toml b/crates/externref-xform/Cargo.toml index f96e7f141..67480c7c6 100644 --- a/crates/externref-xform/Cargo.toml +++ b/crates/externref-xform/Cargo.toml @@ -13,12 +13,12 @@ edition = '2018' [dependencies] anyhow = "1.0" -walrus = "0.17.0" +walrus = "0.18.0" [dev-dependencies] rayon = "1.0" wasmprinter = "0.2" -wast = "17.0" +wast = "21.0" wat = "1.0" [[test]] diff --git a/crates/externref-xform/tests/anyref-param.wat b/crates/externref-xform/tests/anyref-param.wat index b2ad1b902..5b1b23b49 100644 --- a/crates/externref-xform/tests/anyref-param.wat +++ b/crates/externref-xform/tests/anyref-param.wat @@ -24,7 +24,7 @@ local.get 1 call $foo local.get 1 - ref.nullextern + ref.null extern table.set 0 local.get 1 i32.const 1 diff --git a/crates/externref-xform/tests/mixed-export.wat b/crates/externref-xform/tests/mixed-export.wat index fe4290ab0..784877f36 100644 --- a/crates/externref-xform/tests/mixed-export.wat +++ b/crates/externref-xform/tests/mixed-export.wat @@ -33,7 +33,7 @@ local.get 4 call $a local.get 5 - ref.nullextern + ref.null extern table.set 0 local.get 5 i32.const 1 diff --git a/crates/externref-xform/tests/table-grow-intrinsic.wat b/crates/externref-xform/tests/table-grow-intrinsic.wat index 6f4d3c099..0010e8cae 100644 --- a/crates/externref-xform/tests/table-grow-intrinsic.wat +++ b/crates/externref-xform/tests/table-grow-intrinsic.wat @@ -26,7 +26,7 @@ local.get 1 call $foo) (func $foo (type 1) (param i32) - ref.nullextern + ref.null extern i32.const 0 table.grow 0 drop) diff --git a/crates/externref-xform/tests/table-set-null-intrinsic.wat b/crates/externref-xform/tests/table-set-null-intrinsic.wat index 494a64f87..40ba1a6d5 100644 --- a/crates/externref-xform/tests/table-set-null-intrinsic.wat +++ b/crates/externref-xform/tests/table-set-null-intrinsic.wat @@ -26,7 +26,7 @@ call $foo) (func $foo (type 1) (param i32) local.get 0 - ref.nullextern + ref.null extern table.set 0) (func $alloc (type 0) (result i32) i32.const 0) diff --git a/crates/multi-value-xform/Cargo.toml b/crates/multi-value-xform/Cargo.toml index deea5e110..57823f957 100644 --- a/crates/multi-value-xform/Cargo.toml +++ b/crates/multi-value-xform/Cargo.toml @@ -13,12 +13,12 @@ edition = "2018" [dependencies] anyhow = "1.0" -walrus = "0.17.0" +walrus = "0.18.0" [dev-dependencies] rayon = "1.0" wasmprinter = "0.2" -wast = "17.0" +wast = "21.0" wat = "1.0" [[test]] diff --git a/crates/threads-xform/Cargo.toml b/crates/threads-xform/Cargo.toml index 276e72181..f2468ec75 100644 --- a/crates/threads-xform/Cargo.toml +++ b/crates/threads-xform/Cargo.toml @@ -13,5 +13,5 @@ edition = "2018" [dependencies] anyhow = "1.0" -walrus = "0.17.0" +walrus = "0.18.0" wasm-bindgen-wasm-conventions = { path = "../wasm-conventions", version = "=0.2.64" } diff --git a/crates/wasm-conventions/Cargo.toml b/crates/wasm-conventions/Cargo.toml index 4f00a3c72..188fb6292 100644 --- a/crates/wasm-conventions/Cargo.toml +++ b/crates/wasm-conventions/Cargo.toml @@ -10,5 +10,5 @@ description = "Utilities for working with Wasm codegen conventions (usually esta edition = "2018" [dependencies] -walrus = "0.17.0" +walrus = "0.18.0" anyhow = "1.0" diff --git a/crates/wasm-interpreter/Cargo.toml b/crates/wasm-interpreter/Cargo.toml index 37ebc8da9..5698e7b05 100644 --- a/crates/wasm-interpreter/Cargo.toml +++ b/crates/wasm-interpreter/Cargo.toml @@ -14,7 +14,7 @@ edition = '2018' [dependencies] anyhow = "1.0" log = "0.4" -walrus = "0.17.0" +walrus = "0.18.0" wasm-bindgen-wasm-conventions = { path = "../wasm-conventions", version = "0.2.64" } [dev-dependencies] diff --git a/tests/wasm/classes.js b/tests/wasm/classes.js index 9033aa5cd..e8da6d37f 100644 --- a/tests/wasm/classes.js +++ b/tests/wasm/classes.js @@ -200,7 +200,7 @@ exports.js_test_inspectable_classes = () => { assert.deepStrictEqual(inspectable.toJSON(), { a: inspectable.a }); assert.strictEqual(inspectable.toString(), `{"a":${inspectable.a}}`); // Inspectable classes in Node.js have improved console.log formatting as well - assert.strictEqual(console_log_to_string(inspectable), `Inspectable { a: ${inspectable.a} }`); + assert(console_log_to_string(inspectable).endsWith(`{ a: ${inspectable.a} }`)); // Non-inspectable classes do not have a toJSON or toString generated assert.strictEqual(not_inspectable.toJSON, undefined); assert.strictEqual(not_inspectable.toString(), '[object Object]');