WebAssembly / spec

WebAssembly specification, reference interpreter, and test suite.
https://webassembly.github.io/spec/
Other
3.11k stars 439 forks source link

Missing test for elem segment containing `global.get` of imported funcref #1640

Closed sbc100 closed 1 year ago

sbc100 commented 1 year ago

From the wabt bug tracker: https://github.com/WebAssembly/wabt/issues/2201

This should work according to the spec, but currently doesn't under wabt, and its not covered by the spec tests (AFAICT):

(module
  (import "m" "f" (global funcref))
  (table 0 10 funcref)
  (elem (offset (i32.const 0)) funcref (global.get 0))
)