Spec#, nullables and more

Gary Whatmore no at spam.sp
Sat Nov 6 13:57:36 PDT 2010


bearophile Wrote:

> Gary Whatmore:
> 
> > I'm seeing it. The other arguments for non-null types also fall short because non-nulls don't solve basic problems like arrays, basic collections in the library (custom fill policy).
> 
> Arrays and collections are a subset of the nonull problem I am discussing about. I have shown how Spec# solves this problem. D may choose other solutions.
> 
> 
> > Has any mainstream language adopted non-null types?
> 
> Ada has them:
> http://en.wikibooks.org/wiki/Ada_Programming/Types/access#Null_exclusions
> 
> Most functional languages are based on nonullables.
> 
> The GNU version of C has a limited form of them:
> http://gcc.gnu.org/onlinedocs/gcc/Function-Attributes.html#index-g_t_0040code_007bnonnull_007d-function-attribute-2458
> 
> The problem is faced by Eiffel too:
> http://docs.eiffel.com/book/papers/void-safety-how-eiffel-removes-null-pointer-dereferencing

Can't force me to read. I've made my choice of using D already. Nothing will change that. 

> > No they haven't because the idea is broken.
> 
> I don't think so.

Yes they are.


More information about the Digitalmars-d mailing list