summaryrefslogtreecommitdiff
path: root/src/passes/Unsubtyping.cpp
diff options
context:
space:
mode:
authorAlon Zakai <azakai@google.com>2023-10-17 08:58:48 -0700
committerGitHub <noreply@github.com>2023-10-17 08:58:48 -0700
commitede148eaa505d3681abd67b0b4d7de1b82ec05ff (patch)
tree03efacbe949fe82ae0cd91e5b37bc866de950ed1 /src/passes/Unsubtyping.cpp
parent2d1e1501f5da1436f61c8ff5440aca33e25a29e9 (diff)
downloadbinaryen-ede148eaa505d3681abd67b0b4d7de1b82ec05ff.tar.gz
binaryen-ede148eaa505d3681abd67b0b4d7de1b82ec05ff.tar.bz2
binaryen-ede148eaa505d3681abd67b0b4d7de1b82ec05ff.zip
[NFC] Rename getSuperType to getDeclaredSuperType (#6015)
A later PR will add getSuperType which will mean "get the general super type - either declared, or not".
Diffstat (limited to 'src/passes/Unsubtyping.cpp')
-rw-r--r--src/passes/Unsubtyping.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/passes/Unsubtyping.cpp b/src/passes/Unsubtyping.cpp
index 3e88a7f91..87da111f0 100644
--- a/src/passes/Unsubtyping.cpp
+++ b/src/passes/Unsubtyping.cpp
@@ -201,7 +201,7 @@ struct Unsubtyping
void analyzePublicTypes(Module& wasm) {
// We cannot change supertypes for anything public.
for (auto type : ModuleUtils::getPublicHeapTypes(wasm)) {
- if (auto super = type.getSuperType()) {
+ if (auto super = type.getDeclaredSuperType()) {
noteSubtype(type, *super);
}
}
@@ -276,7 +276,7 @@ struct Unsubtyping
Unsubtyping& parent;
Rewriter(Unsubtyping& parent, Module& wasm)
: GlobalTypeRewriter(wasm), parent(parent) {}
- std::optional<HeapType> getSuperType(HeapType type) override {
+ std::optional<HeapType> getDeclaredSuperType(HeapType type) override {
if (auto it = parent.supertypes.find(type);
it != parent.supertypes.end() && !it->second.isBasic()) {
return it->second;