Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion scripts/fuzz_opt.py
Original file line number Diff line number Diff line change
Expand Up @@ -2486,7 +2486,8 @@ def write_commands(commands, filename):
("--cfp-reftest",),
("--gsi",),
("--type-ssa",),
("--type-merging",)}
("--type-merging",),
("--unsubtyping",)}


def get_random_opts():
Expand Down
4 changes: 4 additions & 0 deletions src/passes/Unsubtyping.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -446,6 +446,10 @@ struct Unsubtyping : Pass {
return;
}

if (!getPassOptions().closedWorld) {
Fatal() << "Unsubtyping requires --closed-world";
}

// Initialize the subtype relation based on what is immediately required to
// keep the code and public types valid.
analyzePublicTypes(*wasm);
Expand Down
2 changes: 1 addition & 1 deletion test/lit/passes/issue-7087.wast
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
;; module-level code in TypeSSA and fix the validator so it would have caught
;; the stale type.

;; RUN: wasm-opt %s -all --type-ssa --unsubtyping -S -o - | filecheck %s
;; RUN: wasm-opt %s -all --type-ssa --unsubtyping --closed-world -S -o - | filecheck %s

(module
;; CHECK: (rec
Expand Down
Loading