DIP 1003 Formal Review

Eugene Wissner via Digitalmars-d digitalmars-d at puremagic.com
Tue May 16 11:48:23 PDT 2017


On Tuesday, 16 May 2017 at 18:34:06 UTC, Steven Schveighoffer 
wrote:
> On 5/12/17 12:17 PM, Mike Parker wrote:
>> The first stage of the formal review for DIP 1003 [1], "Remove 
>> body as a
>> Keyword", is now underway. From now until 11:59 PM ET on May 
>> 26 (3:59 AM
>> GMT on May 27), the community has the opportunity to provide 
>> last-minute
>> feedback. If you missed the preliminary review [2], this is 
>> your chance
>> to provide input.
>>
>> At the end of the feedback period, I will submit the DIP to 
>> Walter and
>> Andrei for their final decision. Thanks in advance to those of 
>> you who
>> participate.
>>
>> [1]
>> https://github.com/dlang/DIPs/blob/fbb797f61ac92300eda1d63202157cd2a30ba555/DIPs/DIP1003.md
>>
>>
>> [2] 
>> http://forum.dlang.org/thread/qgxvrbxrvkxtimzvnetu@forum.dlang.org
>
> Before we go down endlessly debating which keywords would work 
> best to replace body here, can someone please inform the crowd 
> why just having body remain as it is now, but *not* be a 
> keyword is unworkable?
>
> The more I think about it, the more I think that option 1 is 
> the far far far superior option. Zero existing code breaks, and 
> we now have access to our own body symbols (and we don't even 
> have to go through a deprecation period). However, if there is 
> a missing lynch pin that shows why this cannot work, then it's 
> better to take it off the table now.
>
> -Steve

1) Consistency with functions without contracts.
2) I wouldn't like to have body optional because: it introduces 
an additional style guide rule: there will be people who will 
omit it and people who will say: explicitely is better, always 
use body.
3) Syntax highlighting: Editors that work with regex will mark 
body in all contexts as a keyword.
4) I know body isn't reserved anywhere, I can use it without 
thinking abot the contexts (good for new comers who may think 
body is a reserved keyword if it is used as such in some 
contexts).


More information about the Digitalmars-d mailing list