(non)nullable types

Christopher Wright dhasenan at gmail.com
Mon Feb 9 04:50:00 PST 2009


Brian wrote:
> On Mon, 09 Feb 2009 04:25:55 +0300, Denis Koroskin wrote:
> 
>> So, let's ask the community: Would you like to see nullable types in D?
>>
>> http://www.micropoll.com/akira/mpview/539369-138652 (please, don't abuse
>> by voting multiple time)
>>
>> Explain your reasoning in newsgroups. Thank you.
> 
> i vote yes, i would absolutely love non-nullable types. in some cases i 
> even use dummy objects to avoid null checks. 

Oh, and I vote no. I think it's needless complexity. I code without any 
special care for null objects, and I get a segfault or 
NullReferenceException maybe once a week, probably less. I've always 
been able to track down the bug very quickly.

Having types be non-nullable by default would harm my productivity a 
fair bit. Having them be optionally non-nullable would be okay, as long 
as the libraries I use don't use non-nullable types.



More information about the Digitalmars-d mailing list