summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rw-r--r--test/passes/dae_all-features.txt (renamed from test/passes/dae_enable-tail-call.txt)12
-rw-r--r--test/passes/dae_all-features.wast (renamed from test/passes/dae_enable-tail-call.wast)11
2 files changed, 23 insertions, 0 deletions
diff --git a/test/passes/dae_enable-tail-call.txt b/test/passes/dae_all-features.txt
index 0b2f6721c..9a1a4d89a 100644
--- a/test/passes/dae_enable-tail-call.txt
+++ b/test/passes/dae_all-features.txt
@@ -279,3 +279,15 @@
)
)
)
+(module
+ (type $funcref_i32_f64_=>_i64 (func (param funcref i32 f64) (result i64)))
+ (type $f32_=>_funcref (func (param f32) (result funcref)))
+ (export "export" (func $1))
+ (func $0 (param $0 funcref) (param $1 i32) (param $2 f64) (result i64)
+ (nop)
+ (unreachable)
+ )
+ (func $1 (param $0 f32) (result funcref)
+ (ref.func $0)
+ )
+)
diff --git a/test/passes/dae_enable-tail-call.wast b/test/passes/dae_all-features.wast
index e70cde1bb..097c144cc 100644
--- a/test/passes/dae_enable-tail-call.wast
+++ b/test/passes/dae_all-features.wast
@@ -161,3 +161,14 @@
)
)
)
+(module
+ (func $0 (param $0 funcref) (param $1 i32) (param $2 f64) (result i64)
+ (nop)
+ (unreachable)
+ )
+ (func "export" (param $0 f32) (result funcref)
+ ;; a ref.func should prevent us from changing the type of a function, as it
+ ;; may escape
+ (ref.func $0)
+ )
+)