Is `alias this` a mistake?
Ola Fosheim Grøstad
ola.fosheim.grostad at gmail.com
Sat Aug 7 06:05:02 UTC 2021
On Thursday, 5 August 2021 at 17:24:56 UTC, IGotD- wrote:
> I never understood the benefit of structs are value types. In
> what use case would you like to pass the value of a struct
> rather than a reference.
Functional programming requires you to conceptually pass by
value, then passing it by reference becomes an optimization. But
in D this is lost since you also can pass by reference. So there
is no advantage to having the struct/class split.
More information about the Digitalmars-d
mailing list