Discussion Thread: DIP 1034--Add a Bottom Type (reboot)--Community Review Round 1
Dennis
dkorpel at gmail.com
Wed May 6 16:39:30 UTC 2020
On Wednesday, 6 May 2020 at 16:22:48 UTC, Meta wrote:
> Why are these defined to cause a compile error?
My reasoning is that the following are all equivalent:
> noreturn x;
> noreturn x = noreturn.init;
> noreturn x = assert(0);
> auto x = assert(0);
> auto x = () {assert(0);} ();
The bottom one gives a compile error today.
> Error: `assert(0)` failed
I don't intend to change that. (This comparison with errors
during CTFE is also mentioned in "Interaction with other language
features" by the way).
More information about the Digitalmars-d
mailing list