[Issue 1869] Semantically returning an array from a funciton is	difficult
    Derek Parnell 
    derek at nomail.afraid.org
       
    Mon Feb 25 17:13:25 PST 2008
    
    
  
On Tue, 26 Feb 2008 00:59:18 +0000 (UTC), d-bugmail at puremagic.com wrote:
> http://d.puremagic.com/issues/show_bug.cgi?id=1869
> 
> ------- Comment #6 from andrei at metalanguage.com  2008-02-25 18:59 -------
> The right thing to do is to manipulate fixed-sized arrays by value,
Why? Or in other words, define "The right thing" and "manipulate". I'm not
disagreeing with you, just asking for clarification.
>  but there
> are a number of consequent issues to solve, e.g. we wouldn't like this:
> 
> writeln("Hello, world!");
> 
> to copy the actual content of the string on the stack and over to the callee.
> Walter is considering making all array constants bind to dynamically-sized
> types by default, and to statically-sized types only when explicitly requested
Thank goodness. I've always thought that assuming string literals are fixed
length arrays was a suboptimal choice. 
I like the [$] syntax too for declaring fixed length array literals.
-- 
Derek
(skype: derek.j.parnell)
Melbourne, Australia
26/02/2008 12:06:37 PM
    
    
More information about the Digitalmars-d-bugs
mailing list