Manu:

Yeah, I've actually noticed this too on a few occasions. It would be nice if array operations would unroll for short arrays. Particularly so for static arrays!

Thanks to Kenji the latest dmd 2.063 solves part of this problem:
http://d.puremagic.com/issues/show_bug.cgi?id=2356

Maybe this improvement is not yet in LDC/GDC.

But avoiding heap allocations for array literals is a change that needs to be discussed.

Bye,
bearophile

Reply via email to