named parameters to functions

BCS ao at pathlink.com
Thu Oct 11 16:52:13 PDT 2007


Reply to Bill,

> BCS wrote:
> 
>> It's have been proposed and favorably received. It's now on the list
>> of things to do at some point in the not to distant future.
>> 
> Favorably received by whom?  I recall lengthy discussions -- I started
> one of them with a post remarkably like Zola's as one of my first
> posts to the D newsgroup -- but I don't recall any favorable reception
> except by other D users. 

Who else matters? As I recall Walter didn't say no.

> And the fact that it didn't make it into
> the WalterAndrei.pdf makes me think that if D gets it at all it will
> be after all that stuff, so methinks it will be "distant future" at
> best.
> 

I was thinking "somewhere between 6 months and D3.0"


>> For now you can sort of fake it with struct literals.
>> 
> Not really.  Struct literals
> (http://www.digitalmars.com/d/1.0/struct.html#StructLiteral) don't
> give you pick-and-choose initialization.
[...]
> 
> Static struct initializers, on the other hand, have the right look,
> x={name:"fred", title:"director"}, but since they only work with
> constants they're not much practical use either.
> 
[...]
> Were you thinking of something else?

<grumble/> 

I though that the {...} form would handle non const. Any Idea why it doesn't?

> 
> --bb
> 





More information about the Digitalmars-d mailing list