> Le 17 avr. 2017 à 10:52, Quincey Morris <[email protected]> > a écrit : > > On Apr 17, 2017, at 01:43 , Jean-Daniel <[email protected] > <mailto:[email protected]>> wrote: >> >> var version: String? { > > A slight correction: this declaration actually must be: > >> dynamic var version: String? { > > > otherwise KVO isn’t guaranteed to work in Swift.
This is a good practice, but I don’t think this is required for computed property, especially if you take care of willChange/didChange manually, as the OP does. _______________________________________________ Cocoa-dev mailing list ([email protected]) Please do not post admin requests or moderator comments to the list. Contact the moderators at cocoa-dev-admins(at)lists.apple.com Help/Unsubscribe/Update your Subscription: https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com This email sent to [email protected]
