> On Mar 3, 2017, at 1:12 PM, Adrian Zubarev <adrian.zuba...@devandartist.com> 
> wrote:
> 
> If I understand the model correctly, then classes structs and enums will have 
> an addition capability for their members.
> 
> static = access(type) access(override, nowhere)
> 
> class = access(type) access(override, everywhere)
> 
> You could combine type into one parameterized access, and make the capability 
> instance the default one, so it will be either or but we don’t have to write 
> instance explicitly like we don’t need it with get.
> 

This isn’t going to work.  The model I am proposing only bounds capabilities.  
It doesn’t distinguish between type and instance members.  We definitely need a 
way to do that and it definitely falls outside the scope of access control.
> 
> 
> 
> -- 
> Adrian Zubarev
> Sent with Airmail
> 
> Am 3. März 2017 um 19:36:31, Adrian Zubarev (adrian.zuba...@devandartist.com 
> <mailto:adrian.zuba...@devandartist.com>) schrieb:
> 
>> I actually found the source, and it’s even an official one. :)
>> 
>> https://developer.apple.com/library/content/documentation/Swift/Conceptual/Swift_Programming_Language/Declarations.html#//apple_ref/doc/uid/TP40014097-CH34-ID483
>>  
>> <https://developer.apple.com/library/content/documentation/Swift/Conceptual/Swift_Programming_Language/Declarations.html#//apple_ref/doc/uid/TP40014097-CH34-ID483>
>> NOTE
>> 
>> In a class declaration, the static keyword has the same effect as marking 
>> the declaration with both the class and final declaration modifiers.
>> It’s overlapping but you might be able to adjust the behavior to cover that 
>> in your model as well ;)
>> 
>> 
>> 
>> -- 
>> Adrian Zubarev
>> Sent with Airmail
>> 
>> Am 3. März 2017 um 18:14:42, Matthew Johnson (matt...@anandabits.com 
>> <mailto:matt...@anandabits.com>) schrieb:
>> 
>>> It would be really helpful if you can find a reference to this somewhere.  
>>> If it’s possible to define static in terms of this system also that would 
>>> be pretty cool.
>> 
> 

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

Reply via email to