compile time 'address'
Stanislav Blinov
stanislav.blinov at gmail.com
Thu Nov 29 19:16:25 UTC 2018
On Thursday, 29 November 2018 at 18:49:27 UTC, Steven
Schveighoffer wrote:
> I don't think it would be a huge stretch to apply this same
> property to function locals, but it would require an
> enhancement request.
>
> -Steve
This compiles since 2.069.2 (according to run.dlang.io):
void main() {
auto c0 = 1;
auto c1 = 2;
static assert(&c0 == &c0);
static assert(&c0 != &c1);
}
I wonder if that is a bug, or that the original question not
compiling is :D
More information about the Digitalmars-d
mailing list