Interesting new Swift keyword I learned about today: "nonmutating."
e.g. UnsafeMutablePointer's
var memory: T { get nonmutating set }
Conversation
I just discovered this myself. I'm using an enum to manage app defaults, and now I can…
AppDefault.Bounciness.intValue = 5
1
Replying to
Yikes. What does that mean? Have a gist?
Yes. :)
That setter *is* mutating. This will break compilation semantics.
4
Show replies

