Final by default?
Walter Bright
newshound2 at digitalmars.com
Wed Mar 12 19:59:10 PDT 2014
On 3/12/2014 6:18 PM, Chris Williams wrote:
> On Thursday, 13 March 2014 at 00:48:15 UTC, Walter Bright wrote:
>> On 3/12/2014 5:18 PM, Andrei Alexandrescu wrote:
>>> We are opposed to having compiler flags define language semantics.
>>
>> Yeah, that's one of those things that always seems like a reasonable idea, but
>> experience with it isn't happy.
>
> I would imagine that the reasons for this goal are 1) to keep the compiler and
> language sane, and 2) insufficient personel to maintain legacy variants.
Maybe surprisingly, it isn't either.
It's because every one of those switches splits the language into two languages.
8 switches means 256 languages. When you're a library vendor, which of those 256
languages are you writing for? What happens when you mix code for language #63
with language #121? It's a nightmare - confusing to people trying to understand
it, and frustrating for those who do.
The combinatorics alone are daunting - 256 times through the test suite. You
have to add introspection so the program can tell which language it is today.
The punishment goes on and on.
More information about the Digitalmars-d
mailing list