www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.learn - Re: const->immutable array argument?

Daniel Murphy:

 It's a bug, the compiler shouldn't be inserting a cast when the value 
 implicitly converts.  It's also a bug when the compiler tries to optimise 
 away the variable to a literal when passing by reference, I've got a patch 
 for this I haven't written up yet. 

http://d.puremagic.com/issues/show_bug.cgi?id=6708 Thank you for all the answers. Bye, bearophile
Sep 21 2011