dst = src rather than src dst

Kirk McDonald kirklin.mcdonald at gmail.com
Thu Sep 6 01:14:05 PDT 2007


Bill Baxter wrote:
> But if Kirk doesn't get it, and Don doesn't chime in with "what a great 
> idea" in the next 5 minutes, well ... it's hopeless.
> 
> --bb

I do "get it" (an "alias" is the type of a symbol, you initialize the 
alias to the symbol, &c &c), I just don't particularly like it very 
much. This is primarily because it's merely a syntax change. If the old 
syntax is retained, we have redundant syntaxes, which is annoying and 
not a good thing. Before removing the current syntax, we have to of 
course consider the existing body of code which would have to be 
changed. (I do not think I need to belabor this point. Remember when 
implicit .ptr conversion was removed? This would be much worse. Removing 
the existing syntax is Not An Option.) Neither option is a winner.

Last and least, I do not not think it's much of an improvement. It is 
not like the existing syntax is ambiguous. It's not even unclear. In 
fact, my most frequent uses of alias render the "rvalue" and "lvalue" of 
the alias abundantly clear, since the rvalue frequently has keywords and 
things in it, or at least is more complicated than just an identifier. 
(Which is usually why I'm aliasing it in the first place.)

-- 
Kirk McDonald
http://kirkmcdonald.blogspot.com
Pyd: Connecting D and Python
http://pyd.dsource.org



More information about the Digitalmars-d mailing list