Proof of concept for v2 - NO duplication, NO `static if` hell, NO difficulty with interoperability

Andrei Alexandrescu SeeWebsiteForEmail at erdani.com
Wed Nov 3 15:02:57 UTC 2021


On 2021-11-02 18:27, Elronnd wrote:
> On Tuesday, 2 November 2021 at 20:24:21 UTC, Andrei Alexandrescu wrote:
>>> Not it all, std2 sounds to me like std.experimental just with a 
>>> different name.
>>
>> Must have been a miscommunication on my part. The two couldn't be more 
>> different.
> 
> I don't think the concern is that they are _intended_ to be similar, but 
> that they will end up that way.
> 
>> std.experimental:
>> - Intent is to be moved to std when ready, where it ADDS functionality
> 
> And yet, std.experimental seems to be where code goes to die. 
> std.sumtype exists, probably only because pbackus didn't let it go into 
> std.experimental.

This seems to presuppose I was making the argument std.experimental is good.

FWIW I fully supported and encouraged Paul to merge his work straight 
into std.

> std.v2 is similar in at least one respect: it does not start off stable, 
> and will presumably get that way at some point.  At what point do we say 
> 'std.v2 is now stable'?  Well, that's exactly the same question we ask 
> about things in std.experimental.

The answer to the same question is radically different for the two.

1. For experimental: has the artifact and its API mature? It's a vague 
question.

2. For stdv2: does it cover all symbols from std? It's a very precise 
question.

> Here's one way it could be done: stabilize individual components of it 
> at a time.  So, say: get rid of autodecoding and maybe the class range 
> thing, and then say 'all std.v2 range interfaces are stable; others may 
> not be'.  And at that point it is immediately useful.  Complete, stable 
> std.v2 just happens when all of its components are stabilised.

I don't think there's a need for such a staggered release. Use std2alpha 
or whatever until all components are ported, then rename and release 
officially.


More information about the Digitalmars-d mailing list