Andrew Kelley
f4e051e35d
Sema: fix comptime break semantics
...
Previously, breaking from an outer block at comptime would result in
incorrect control flow. Now there is a mechanism, `error.ComptimeBreak`,
similar to `error.ComptimeReturn`, to send comptime control flow further
up the stack, to its matching block.
This commit also introduces a new log scope. To use it, pass
`--debug-log sema_zir` and you will see 1 line per ZIR instruction
semantically analyzed. This is useful when you want to understand what
comptime control flow is doing while debugging the compiler.
One more `switch` test case is passing.
2022-01-17 15:23:50 -07:00
..
2022-01-17 16:35:41 +01:00
2022-01-15 15:18:25 -07:00
2022-01-15 15:18:25 -07:00
2022-01-14 13:29:58 -05:00
2021-11-30 23:32:47 +00:00
2022-01-15 15:18:25 -07:00
2022-01-17 16:54:48 +02:00
2021-12-10 23:09:02 +01:00
2022-01-02 13:16:17 -07:00
2022-01-11 12:41:26 -05:00
2021-11-26 19:59:33 -07:00
2021-12-19 00:24:45 -05:00
2022-01-15 00:17:25 -07:00
2022-01-13 20:02:11 +01:00
2021-10-22 12:50:25 +02:00
2021-12-19 00:24:45 -05:00
2021-11-30 23:32:47 +00:00
2020-12-07 17:27:09 -07:00
2022-01-14 12:39:06 -07:00
2021-11-30 23:32:47 +00:00
2021-11-30 23:32:47 +00:00
2022-01-10 23:40:15 +01:00
2022-01-02 13:16:17 -07:00
2022-01-02 13:16:17 -07:00
2022-01-13 20:02:11 +01:00
2022-01-15 15:18:25 -07:00
2022-01-13 20:02:11 +01:00
2022-01-07 00:06:06 -05:00
2022-01-17 15:23:50 -07:00
2022-01-02 13:16:17 -07:00
2021-11-30 23:32:47 +00:00
2022-01-15 15:18:25 -07:00
2021-11-30 23:32:47 +00:00
2021-11-30 23:32:47 +00:00
2022-01-13 22:13:44 -07:00
2021-11-30 23:32:47 +00:00
2021-12-30 14:39:06 +01:00
2022-01-17 15:23:50 -07:00
2022-01-11 13:33:53 +01:00
2021-12-16 03:01:13 -07:00
2021-12-03 17:33:20 -07:00
2021-11-30 23:32:47 +00:00
2022-01-07 00:06:06 -05:00
2022-01-17 17:16:48 +02:00
2022-01-14 23:08:11 -07:00
2021-11-30 23:32:47 +00:00
2022-01-15 00:17:25 -07:00
2021-11-09 18:31:03 -07:00
2021-11-30 23:32:47 +00:00
2021-09-24 13:39:20 -04:00
2021-09-07 21:49:08 -06:00
2020-09-21 21:14:01 -07:00
2021-09-01 17:54:07 -07:00
2021-08-15 18:06:29 -07:00
2021-08-15 18:06:29 -07:00
2021-08-15 18:06:29 -07:00
2021-10-20 17:58:30 -04:00
2021-10-20 17:58:30 -04:00
2021-09-30 21:38:04 -07:00
2021-12-28 01:53:58 -07:00
2021-12-28 01:53:58 -07:00
2022-01-13 22:13:44 -07:00