July 25

On Monday, 22 July 2024 at 16:32:38 UTC, Nick Treleaven wrote:

> >

and yet it supposedly uses the GC just for iteration?

Do you have an example? The following compiles:

void main() @nogc{
    int[string] aa;
    foreach (k, v; aa)
        assert(v);
}

I might’ve been thinking about how it couldn’t be used in @nogc code a year or two ago when we didn’t really have inferred @nogc.

July 25

On Thursday, 25 July 2024 at 07:46:33 UTC, IchorDev wrote:

>

On Monday, 22 July 2024 at 16:00:05 UTC, Nick Treleaven wrote:

>

front can't return a tuple, because the range has to store a pointer to a value so front.value can be mutated.

This won’t be an issue anymore once we have ref fields.

Where is that proposed? Is that really going to be @safe?

July 25

On Thursday, 25 July 2024 at 15:30:54 UTC, Nick Treleaven wrote:

>

Where is that proposed? Is that really going to be @safe?

Oh shoot it’s only for local variables, my bad: https://forum.dlang.org/thread/v11mh1$fvs$1@digitalmars.com

Back on topic: how should we go about remedying this issue?

1 2
Next ›   Last »