From a1b88267bb977cb5fdba614b5f61fa7c84f51bf6 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Mon, 7 Oct 2024 15:37:53 -0700 Subject: Add explicit errors on unhandled instructions in Flatten (#6992) This error makes #6989 less confusing. --- src/passes/Flatten.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/passes/Flatten.cpp') diff --git a/src/passes/Flatten.cpp b/src/passes/Flatten.cpp index 8ddd8632a..37fa15b11 100644 --- a/src/passes/Flatten.cpp +++ b/src/passes/Flatten.cpp @@ -329,6 +329,11 @@ struct Flatten } } + if (curr->is() || curr->is()) { + Fatal() << "Unsupported instruction for Flatten: " + << getExpressionName(curr); + } + // continue for general handling of everything, control flow or otherwise curr = getCurrent(); // we may have replaced it // we have changed children -- cgit v1.2.3