Difficulty copying multi dimensional static array to dynamic array.

Oskar Linde oskar.lindeREM at OVEgmail.com
Tue Feb 26 10:13:35 PST 2008


Derek Parnell wrote:
> On Tue, 26 Feb 2008 00:17:10 +0000, Spacen Jasset wrote:
> 
>> I don't see the mystery. Arrays are *always* passed by reference.
> 
> Thanks. I was still under the illusion that fixed length arrays were passed
> by value. Maybe this will stick in my head now ;-)
> 
> On the question of returning fixed-length arrays, it does seem like its
> something that the compiler should be able to do. Good luck with that one.

I have long lobbied for it, and Walter has actually said that at some 
point static arrays in D will become value types. Once they are, heaps 
of horrible workarounds will become obsolete.

-- 
Oskar


More information about the Digitalmars-d-learn mailing list