I approved DIP1036e

Timon Gehr timon.gehr at gmx.ch
Wed Jan 17 23:22:02 UTC 2024


On 1/17/24 15:26, RazvanN wrote:
> On Wednesday, 17 January 2024 at 14:19:37 UTC, ryuukk_ wrote:
>> On Wednesday, 17 January 2024 at 02:16:01 UTC, zjh wrote:
>>> On Tuesday, 16 January 2024 at 20:38:37 UTC, Walter Bright wrote:
>>>> https://github.com/dlang/dmd/pull/15715
>>>>
>>>> I was unconvincing in my arguments, there was too much acrimony, and 
>>>> its effects do not affect the rest of the language.
>>>
>>>
>>>
>>> In fact, two switches can also be provided for continuous feedback 
>>> during use.
>>> We should also establish an `experimental mechanism` that allows for 
>>> the revocation of the switch if it causes significant harm!
>>
>> I agree with that
>>
>> It should have been like other features, both under -preview switch, 
>> then a period of several months for testing, then a debate in forums 
>> about wich is better
>>
>> Do this with tuple, pattern matching, and tagged union, so people can 
>> test, give feedback, propose improvements without commitment for 
>> integration
>>
>>
>> I already use 2 preview switches in my project:
>>
>> -preview=rvaluerefparam
>> -preview=bitfields
>>
>>
>> I love rvaluerefparam, it should go core, but bitfields is imo bad, 
>> i'd prefer to be able to get bit specific integer type instead..
>>
> 
> Please be careful with that switch as it has a lot of bugs (and as far 
> as I remember it's not completely implemented). I have tried turning it 
> on by default in the compiler and was not able to compile phobos 
> (however, I do not remember what the problems were).
> 
> RazvanN
> 
> 

Well, Phobos relies on rvalues not binding to ref parameters in order to 
check via `__traits(compiles, ...)` whether something is an lvalue.




More information about the Digitalmars-d mailing list