> On Aug 19, 2017, at 1:29 PM, Michel Fortin via swift-evolution 
> <swift-evolution@swift.org> wrote:
> 
> I'm not actually that interested in the meaning of value semantics here. I'm 
> debating the appropriateness of determining whether something can be done in 
> another thread based on the type a function is attached to. Because that's 
> what the ValueSemantical protocol wants to do. ValueSemantical, as a 
> protocol, is whitelisting the whole type while in reality it should only 
> vouch for a specific set of safe functions on that type.


To state more explicitly what I think you might be implying here: In principle, 
we could have developers annotate value-semantic *members* instead of 
value-semantic *types* and only allow value-semantic members to be used on 
parameters to an actor. But I worry this might spread through the type system 
like `const` in C++, forcing large numbers of APIs to annotate parameters with 
`value` and restrict themselves to value-only APIs just in case they happen to 
be used in an actor.

-- 
Brent Royal-Gordon
Architechies

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

Reply via email to