On 07.01.2012 04:18, Andrei Alexandrescu wrote:
On 1/6/12 5:52 PM, Walter Bright wrote:
Support the 10 vector types as basic types, support them with the
arithmetic infix operators, and use intrinsics for the rest of the
operations. I believe this scheme:

1. will look better in code, and will be easier to use
2. will allow for better error detection and more comprehensible error
messages when things are misused
3. will generate better code
4. shouldn't be hard to implement, as I already did most of the work
when I did the SIMD support for float and double.

I think it would be great to try avoiding the barbarism of adding 10
built-in types and a bunch of built-ins.

Historically, D has erred heavily on the side of building in the
compiler. Consider the the complex numbers affair, in tow with crackpot
science arguments on why they're a must. It's great that embarrassment
is behind us.


> Also consider how the hard-coding of associative arrays in
an awkward interface inside the runtime has stifled efficient
implementations, progress, and innovation in that area. Still a lot of
work needed there, too, to essentially undo a bad decision.

Sorry Andrei, I have to disagree with that in the strongest possible terms. I would have mentioned AAs as a very strong argument in the opposite direction!

Moving AAs from a built-in to a library type has been an unmitigated disaster from the implementation side. And it has so far brought us *nothing* in return. Not "hardly anything", but *NOTHING*. I don't even have any idea of what good could possibly come from it. Note that you CANNOT have multiple implementations on a given platform, or you'll get linker errors! So I think there is more pain to come from it.
It seems to have been motivated by religious reasons and nothing more.
Why should anyone believe the same argument again?

Reply via email to