Re: When is exception throwing @nogc with -dip1008?

2020-06-22 Thread Steven Schveighoffer via Digitalmars-d-learn
On 6/22/20 10:36 AM, Per Nordlöw wrote: On Monday, 22 June 2020 at 14:10:15 UTC, Mike Parker wrote: https://github.com/dlang/DIPs/blob/master/DIPs/other/DIP1008.md The spec says: " The only place a refcounted Throwable is ever created is when the following statement is in the user code:

Re: When is exception throwing @nogc with -dip1008?

2020-06-22 Thread Per Nordlöw via Digitalmars-d-learn
On Monday, 22 June 2020 at 14:10:15 UTC, Mike Parker wrote: https://github.com/dlang/DIPs/blob/master/DIPs/other/DIP1008.md The spec says: " The only place a refcounted Throwable is ever created is when the following statement is in the user code: throw new E(string); " What other typical

Re: When is exception throwing @nogc with -dip1008?

2020-06-22 Thread Mike Parker via Digitalmars-d-learn
On Monday, 22 June 2020 at 13:59:22 UTC, Per Nordlöw wrote: I can't find any docs on DIP-1008. The link https://github.com/dlang/DIPs/blob/master/DIPs/DIP1008.md given in the release notes here Ref: https://dlang.org/changelog/2.079.0.html#dip1008 is broken.

Re: When is exception throwing @nogc with -dip1008?

2020-06-22 Thread Per Nordlöw via Digitalmars-d-learn
On Monday, 22 June 2020 at 13:59:22 UTC, Per Nordlöw wrote: I can't find any docs on DIP-1008. The link https://github.com/dlang/DIPs/blob/master/DIPs/DIP1008.md is broken. Found the postponed spec here: https://github.com/dlang/DIPs/blob/master/DIPs/other/DIP1008.md

When is exception throwing @nogc with -dip1008?

2020-06-22 Thread Per Nordlöw via Digitalmars-d-learn
Under what circumstances is exception throwing currently `@nogc` if the dmd flag `-dip1008` is used? For instance in code such as: void main() @nogc { throw new Exception("I'm @nogc now"); } Are all exceptions forced to be statically allocated when -dip1008 is used or can exception