DIP 1006 - Preliminary Review Round 1

rikki cattermole via Digitalmars-d digitalmars-d at puremagic.com
Wed Apr 12 04:53:01 PDT 2017


On 12/04/2017 12:48 PM, Nicholas Wilson wrote:
> On Wednesday, 12 April 2017 at 11:32:37 UTC, rikki cattermole wrote:
>> On 12/04/2017 12:25 PM, Mike Parker wrote:
>>> DIP 1006 is titled "Providing more selective control over contracts".
>>>
>>> https://github.com/dlang/DIPs/blob/master/DIPs/DIP1006.md
>>>
>>> All review-related feedback on and discussion of the DIP should occur in
>>> this thread. The review period will end at 11:59 PM ET on April 26 (3:59
>>> AM GMT), or when I make a post declaring it complete.
>>>
>>> At the end of Round 1, if further review is deemed necessary, the DIP
>>> will be scheduled for another round. Otherwise, it will be queued for
>>> the formal review and evaluation by the language authors.
>>>
>>> Thanks in advance to all who participate.
>>>
>>> Destroy!
>>
>> How exactly does this affect unittests?
>> From what I can see, in none mode unittests won't have any asserts,
>> which is clearly a problem.
>
> This is a -release style optimisation and would not be expected to be in
> dev/testing. Also unittest asserts call a different druntime function
> (IIRC) and therefore _should_ logically be under the control of
> -unittest and not affected by dip1006 OR be an invalid flag combination.

Please make it explicit that asserts are only in invariant and in/out 
blocks are affected. With a note about unittests, just to remove this 
possible incorrect implementation detail.

I am not happy with the args passed to the switch, but I can't think of 
an alternative names, so I am happy with how the DIP is including the 
above statements.


More information about the Digitalmars-d mailing list