Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 20:57:17 UTC, Neia Neutuladh wrote: On Tuesday, 19 September 2017 at 15:11:31 UTC, Craig Black wrote: [...] You want to ensure that it can never refer to GC memory. The type system does not contain that information. It doesn't say whether an object was

Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 13:59:27 UTC, Jonathan M Davis wrote: On Tuesday, September 19, 2017 13:11:03 Craig Black via Digitalmars-d wrote: I've recently tried coding in D again after some years. One of my earlier concerns was the ability to code without the GC, which seemed difficult

Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 13:11:03 UTC, Craig Black wrote: I've recently tried coding in D again after some years. One of my earlier concerns was the ability to code without the GC, which seemed difficult to pull off. To be clear, I want my programs to be garbage collected, but I want

Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
I've recently tried coding in D again after some years. One of my earlier concerns was the ability to code without the GC, which seemed difficult to pull off. To be clear, I want my programs to be garbage collected, but I want to use the GC sparingly so that the mark and sweep collections

Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 13:32:59 UTC, Eugene Wissner wrote: On Tuesday, 19 September 2017 at 13:11:03 UTC, Craig Black wrote: I've recently tried coding in D again after some years. One of my earlier concerns was the ability to code without the GC, which seemed difficult to pull off.

Re: Specifying @nogc on structs seems to have no effect

2017-09-20 Thread Craig Black via Digitalmars-d
On Wednesday, 20 September 2017 at 02:43:44 UTC, B4s1L3 wrote: On Tuesday, 19 September 2017 at 13:11:03 UTC, Craig Black wrote: I've recently tried coding in D again after some years. One of my earlier concerns was the ability to code without the GC, which seemed difficult to pull off. To

Re: Specifying @nogc on structs seems to have no effect

2017-09-20 Thread Craig Black via Digitalmars-d
On Wednesday, 20 September 2017 at 02:43:44 UTC, B4s1L3 wrote: It's another way of doing things. It's less strict than checking all the functions. note: the script can be run directly by passing the file to DUB (single file package). Wow! Yeah that seems like almost exactly what I want.

Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 14:34:10 UTC, Mike Parker wrote: On Tuesday, 19 September 2017 at 14:22:21 UTC, Craig Black wrote: Thank you for your response. The @nogc attribute is good, but in my opinion it is incomplete if all types still require scanning. The purpose of not employing

Re: Specifying @nogc on structs seems to have no effect

2017-09-19 Thread Craig Black via Digitalmars-d
On Tuesday, 19 September 2017 at 15:15:05 UTC, Steven Schveighoffer wrote: On 9/19/17 10:22 AM, Craig Black wrote: On Tuesday, 19 September 2017 at 13:59:27 UTC, Jonathan M Davis wrote: On Tuesday, September 19, 2017 13:11:03 Craig Black via Digitalmars-d wrote: I've recently tried coding in D