diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/passes/Precompute.cpp | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/passes/Precompute.cpp b/src/passes/Precompute.cpp index d2f3543ad..822b8ab16 100644 --- a/src/passes/Precompute.cpp +++ b/src/passes/Precompute.cpp @@ -27,7 +27,6 @@ // looked at. // -#include "ir/effects.h" #include "ir/iteration.h" #include "ir/literal-utils.h" #include "ir/local-graph.h" @@ -195,6 +194,14 @@ public: } return Literal(canonical, curr->type.getHeapType()); } + + Flow visitStringEncode(StringEncode* curr) { + // string.encode_wtf16_array is effectively an Array write operation, so + // just like ArraySet and ArrayCopy above we must mark it as disallowed + // (due to side effects). (And we do not support other operations than + // string.encode_wtf16_array anyhow.) + return Flow(NONCONSTANT_FLOW); + } }; struct Precompute |