aboutsummaryrefslogtreecommitdiff
path: root/src/codegen.zig
diff options
context:
space:
mode:
authorEvan Haas <evan@lagerdata.com>2021-04-08 09:25:52 -0700
committerAndrew Kelley <andrew@ziglang.org>2021-04-13 11:45:03 -0700
commite761e0ac18aa1eab22b9547d702067910ed82c4a (patch)
tree2051a37e060386eab8b52152b6f478bc6e54945a /src/codegen.zig
parent36a33c99e3bc0825ada2ce1b374c32b4d6dee6b0 (diff)
downloadzig-e761e0ac18aa1eab22b9547d702067910ed82c4a.tar.gz
zig-e761e0ac18aa1eab22b9547d702067910ed82c4a.zip
translate-c: wrap switch statements in a while (true) loop
This allows `break` statements to be directly translated from the original C. Add a break statement as the last statement of the while loop to ensure we don't have an infinite loop if no breaks / returns are hit in the switch. Fixes #8387
Diffstat (limited to 'src/codegen.zig')
0 files changed, 0 insertions, 0 deletions