2 ms·
I vaguely recall that gcc supports this even in C mode. The underlying problem has to do with whether the IR has first-class concept of arbitrary lvalue or whe
by dfox 4y ago
I vaguely recall that gcc supports this even in C mode.
The underlying problem has to do with whether the IR has first-class concept of arbitrary lvalue or whether the frontend has to convert lvalues that get passed around to some pointer-like thing.
It might look irrelevant for discussion of low-level AOT compilers, but it is also interesting to compare how this is implemented in dynamic/“scripting” runtimes and how the choice of underlying implementation of the concept of “lvalue”/“place” influences the user visible language. Somewhat notably first draft of Common Lisp had something akin to first-class lvalues and the final standard replaced all that with significantly simpler mechanism that purely relies on macros.