f8fe517d12
We were caching the ConstExprValue of string literals, which works if you can never modify ConstExprValues. This premise is broken with `comptime var ...`. So I implemented an optimization in ConstExprValue arrays, where it stores a `Buf *` directly rather than an array of ConstExprValues for the elements, and then similar to array of undefined, it is expanded into the canonical form when necessary. However many operations can happen directly on the `Buf *`, which is faster. Furthermore, before a ConstExprValue array is expanded into canonical form, it removes itself from the string literal cache. This fixes the issue, because before an array element is modified it would have to be expanded. closes #1076 |
||
---|---|---|
.. | ||
394.zig | ||
655_other_file.zig | ||
655.zig | ||
656.zig | ||
726.zig | ||
828.zig | ||
920.zig | ||
1076.zig | ||
1111.zig | ||
1277.zig | ||
1322.zig | ||
1381.zig | ||
1421.zig | ||
1442.zig |