summaryrefslogtreecommitdiff
path: root/src/ir/bits.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ir/bits.h')
-rw-r--r--src/ir/bits.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/ir/bits.h b/src/ir/bits.h
index 950864a23..dc02bd8f8 100644
--- a/src/ir/bits.h
+++ b/src/ir/bits.h
@@ -413,6 +413,8 @@ Index getMaxBits(Expression* curr,
// a tee passes through the value
return getMaxBits(set->value, localInfoProvider);
} else if (auto* get = curr->dynCast<LocalGet>()) {
+ // TODO: Should this be optional?
+ assert(localInfoProvider);
return localInfoProvider->getMaxBitsForLocal(get);
} else if (auto* load = curr->dynCast<Load>()) {
// if signed, then the sign-extension might fill all the bits