Major performance problem with std.array.front()

Kagamin spam at here.lot
Fri Mar 7 06:44:41 PST 2014


On Friday, 7 March 2014 at 14:13:54 UTC, Adam D. Ruppe wrote:
> On Friday, 7 March 2014 at 10:44:46 UTC, Kagamin wrote:
>> Now it's passed by value.
>
> That won't work for operator overloading though (which is the 
> really interesting case here).

Alternatively for small methods you can rely on inlining, which 
dereferences the argument. If the method is big, the reference is 
probably unimportant.


More information about the Digitalmars-d mailing list