mlugg
4976b58ab1
Prevent analysis of functions only referenced at comptime
...
The idea here is that there are two ways we can reference a function at runtime:
* Through a direct call, i.e. where the function is comptime-known
* Through a function pointer
This means we can easily perform a form of rudimentary escape analysis
on functions. If we ever see a `decl_ref` or `ref` of a function, we
have a function pointer, which could "leak" into runtime code, so we
emit the function; but for a plain `decl_val`, there's no need to.
This change means that `comptime { _ = f; }` no longer forces a function
to be emitted, which was used for some things (mainly tests). These use
sites have been replaced with `_ = &f;`, which still triggers analysis
of the function body, since you're taking a pointer to the function.
Resolves : #6256
Resolves : #15353
2023-05-29 23:06:08 +01:00
..
2022-11-21 17:17:02 -07:00
2022-06-17 16:38:59 -07:00
2022-06-17 16:38:59 -07:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-08-22 11:19:20 +03:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2023-05-11 11:33:47 +03:00
2023-04-25 11:23:40 -07:00
2023-01-23 13:48:36 -05:00
2023-01-23 13:48:36 -05:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2023-05-29 23:06:08 +01:00
2022-05-06 22:41:00 -07:00
2022-12-18 01:42:15 +02:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2023-04-15 10:33:08 -07:00
2023-02-18 19:17:21 -07:00
2022-06-17 16:38:59 -07:00
2023-02-18 19:17:21 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-10-09 11:09:41 -07:00
2022-10-09 11:09:41 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2023-01-01 16:44:28 -05:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2023-01-24 13:06:59 +02:00
2023-04-25 11:23:40 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2023-04-05 22:05:10 -07:00
2022-10-09 13:42:39 -07:00
2023-04-05 22:05:10 -07:00
2023-04-05 22:05:10 -07:00
2023-04-05 22:05:10 -07:00
2023-04-05 22:05:10 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2023-01-01 16:44:28 -05:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-10-18 14:15:16 +03:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2023-02-18 17:07:35 +00:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-16 00:18:25 +01:00
2022-08-22 11:19:20 +03:00
2023-02-24 13:27:02 -05:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-10-09 11:09:41 -07:00
2022-10-09 11:09:41 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-10-13 12:53:20 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2023-02-24 13:27:02 -05:00
2023-02-24 13:27:02 -05:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2023-02-12 00:10:27 +02:00
2023-02-12 00:10:27 +02:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2023-02-11 14:25:01 +02:00
2023-02-24 13:27:02 -05:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-13 13:14:20 +02:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-12-28 14:57:17 +01:00
2023-04-05 22:05:10 -07:00
2022-12-28 14:57:17 +01:00
2022-06-17 16:38:59 -07:00
2022-06-17 16:38:59 -07:00
2023-04-05 22:05:10 -07:00
2022-12-28 14:57:17 +01:00
2023-04-05 22:05:10 -07:00
2022-12-28 14:57:17 +01:00
2022-12-29 17:59:44 -05:00
2022-12-28 14:57:17 +01:00
2023-04-05 22:05:10 -07:00
2022-12-28 14:57:17 +01:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-05-06 22:41:00 -07:00
2022-11-16 13:08:41 +02:00
2022-11-16 13:08:41 +02:00
2023-04-28 13:24:43 -07:00
2022-11-16 13:08:41 +02:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00
2022-12-28 14:57:17 +01:00