Struct Initialization syntax

rikki cattermole rikki at cattermole.co.nz
Tue Jul 24 03:59:53 UTC 2018


On 24/07/2018 6:43 AM, kinke wrote:
> On Monday, 23 July 2018 at 17:32:23 UTC, aliak wrote:
>> Can we just consider that named struct init syntax *is* a generated 
>> named constructor?
>>
>> If named arguments choose a different syntax then you have no 
>> conflict. If they go with the same (i.e. option 2) then you have 
>> seamless consistency.
> 
> +1. And hoping for the latter, seamless consistency.

Based upon my DIP that is in the queue for named arguments, it would be 
trivial for this DIP to make it so a named parameter constructor can 
override the default behavior and I think that this is the best way forward.


More information about the Digitalmars-d mailing list