Blog Post: Beating std::visit Without Really Trying

Atila Neves atila.neves at gmail.com
Wed Oct 16 16:00:51 UTC 2019


On Wednesday, 16 October 2019 at 15:23:01 UTC, Paolo Invernizzi 
wrote:
> On Wednesday, 16 October 2019 at 15:01:17 UTC, Atila Neves 
> wrote:
>
>>> [...]
>>
>> I don't think it's political: the change implies breakage for 
>> downstream users who inherit from the class who might not even 
>> care about @nogc.
>
> The proposed solution is to "add" a new @nogc method, with the 
> correct signature, so that if someone want to write application 
> and care about @nogc and @safe can rely on the D standard 
> library being complaint to that.
>
> What's the problem with that, if not a _political_ one? We have 
> a "wrong" signature, we don't break anything, but we add 
> "correct" signature. That's what already was done in Mutex with 
> lock_nothrow, but it's seen as "annoying to have to define/use 
> alternate names for all the methods, though"

Oh. I missed that.


More information about the Digitalmars-d-announce mailing list