Unified handling of basic and user-defined type proposal

Rob T rob at ucora.com
Tue Nov 27 09:48:59 PST 2012


What you are suggesting makes perfect sense. IMHO the biggest 
source of waste in any language both natural and contrived (and 
with many things outside of languages) is inconsistency. The more 
differences and incompatibilities there are between the various 
constructs, the more complexity is introduced into the system, 
often needlessly. Even if you have to fake it, making x 
consistent with y is often worth doing, and IMO it can be done 
with zero cost in terms of performance and other forms of 
overhead.

Unfortunately D was modeled after C++, a legacy language built on 
top of an inconsistent foundation. Even though D is an 
improvement, I think D has inherited at its foundation a 
crippling affect that will be impossible to shake off fully. The 
language would have to fundamentally change to become consistent.

No matter, as you've suggested (and I think shown), D can still 
be adjusted to get rid of at least some of the crippling effects 
of inconsistency, and even a small fix to an inconsistency can 
potentially create a big improvement.

--rt



More information about the Digitalmars-d mailing list