> On Jul 18, 2017, at 15:56, Slava Pestov via swift-users 
> <swift-users@swift.org> wrote:
> 
> 
>> On Jul 18, 2017, at 3:54 PM, Chris McIntyre <nothingwasdelive...@gmail.com 
>> <mailto:nothingwasdelive...@gmail.com>> wrote:
>> 
>> Was it ever explained why the syntax is different?
>> 
> 
> Oh. I think convenience initializers on classes are marked as such explicitly 
> because convenience vs designated has an effect on the ABI of an initializer, 
> for the purposes of inheritance. With a value type, it doesn’t change 
> anything about how the initializer is used externally.
> 
> Yeah, probably the AST printer should not print the ‘convenience’ keyword on 
> non-class initializers.

FWIW I tried to stop doing this in the actual AST representation and it caused 
problems 
(https://github.com/apple/swift/pull/8540/commits/4f6e88b009ad07edd35343c2c9b758f03029a731
 <https://github.com/apple/swift/pull/8540>). That's probably the right way for 
us to go for real, though, not just hiding the kind in the printer.

Jordan

_______________________________________________
swift-users mailing list
swift-users@swift.org
https://lists.swift.org/mailman/listinfo/swift-users

Reply via email to