Origins of the D Programming Language

Adam D. Ruppe destructionator at gmail.com
Sat Dec 1 16:16:32 UTC 2018


On Saturday, 1 December 2018 at 11:02:51 UTC, Kagamin wrote:
> Ugh, purity shouldn't be a default.

You'd just put "impure" on functions that need to access more.

And keep in mind too that D's pure basically means "no 
non-immutable globals". So if you need to access one of those, 
you just slap impure on it and go your merry way. So it isn't 
very restrictive at all and the slight hassle of saying "impure" 
might even lead to encouraging better design.

I'm about as traditional as D coders come, but I'd welcome that. 
(In fact, I'm of the opinion that these attributes are 
near-useless because they aren't default - there's nothing to 
gain for library writers to use them right now, whereas if it was 
swapped, you would have something to gain: your design would 
work.)


More information about the Digitalmars-d mailing list