On Friday, 19 November 2021 at 17:38:53 UTC, Merlin Diavova wrote:
I'm trying to figure out the most efficient way to create
modified instances of immutable structs.
This might not be the best way but it is a kinda cool trick
anyway: structs have a `tupleof` property you can slice. So you
can
Hi all,
I'm trying to figure out the most efficient way to create
modified instances of immutable structs.
Currently, I'm doing the following:
```d
immutable struct Node {
string label;
Node parentNode;
NetworkPort port;
auto withLabel(string newLabel)