How can we make it easier to experiment with the compiler?

Walter Bright newshound2 at digitalmars.com
Mon May 24 09:53:42 UTC 2021


On 5/23/2021 10:55 PM, Andrei Alexandrescu wrote:
> One problem with that is code duplication.
Sure. But in the outbuffer case, the duplication stems from backend being used 
in multiple projects.

It's hard to have perfection, and if getting to perfection means driving off a 
cliff (!) it's better to just live with a bit of imperfection here and there.

I don't like having two outbuffers, but the cure is worse for that particular case.

There's even another implementation of outbuffer in Phobos (because I thought 
outbuffer was generally very useful):

https://dlang.org/phobos/std_outbuffer.html

But here we run into our rule that dmd shouldn't rely on Phobos. Compromise is 
inevitable. Outbuffer isn't a spike we need to impale ourselves on. There are 
plenty of other encapsulation problems that could be improved, like target.d.


More information about the Digitalmars-d mailing list