[:] as empty associative array literal, plus warning for null

Dicebot public at dicebot.lv
Fri Jul 5 00:54:29 PDT 2013


On Thursday, 4 July 2013 at 23:25:38 UTC, Andrei Alexandrescu 
wrote:
> Where does the whole "stronger typing" comes in? This is 
> poppycock. We need real arguments here.
>
> Andrei

More values typeof([]) can be implicitly converted to - weaker 
typing, that simple. Actually I'd love to be able to specify 
precisely typed empty array literal, like [uint] or [uint:bool] 
but can't find a good syntax to propose. Currently array literals 
are very special and is does harm the type system.


More information about the Digitalmars-d mailing list