Skip to content

Commit 7eb871f

Browse files
authored
Update compiler/noirc_evaluator/src/ssa/opt/constant_folding.rs
1 parent 303e396 commit 7eb871f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

compiler/noirc_evaluator/src/ssa/opt/constant_folding.rs

+1
Original file line numberDiff line numberDiff line change
@@ -726,6 +726,7 @@ impl<'brillig> Context<'brillig> {
726726
// Should we consider calls to slice_push_back and similar to be mutating operations as well?
727727
if let Store { value: array, .. } | ArraySet { array, .. } = instruction {
728728
if function.dfg.is_global(*array) {
729+
// Early return as we expect globals to be immutable.
729730
return;
730731
};
731732

0 commit comments

Comments
 (0)