[swift-evolution] [Review] SE-0030 Property Behaviors

Brent Royal-Gordon brent at architechies.com
Thu Feb 11 15:36:15 CST 2016


> Where [lazy] is currently used, could the syntax instead be #behavior(lazy)? That prevents a possible future naming clash, keeps the # meaning compiler-magic, and doesn't use the [], which is contentious.

I think that if we go down this road, @behavior(lazy) or just @lazy is strictly superior. We already have the @ sigil for attributes; we don't need to introduce another sigil for no apparent reason.

(But unless we're going to use the latter syntax and say "all @s are behaviors, we just haven't formalized func/type/etc. behaviors yet" so we finally have an idea of what @ means, I don't think either of these syntaxes is better than the one proposed.)

-- 
Brent Royal-Gordon
Architechies



More information about the swift-evolution mailing list