Closed beltex closed 9 years ago
This no longer applies since SMC is now a struct, not a class. Even so, the general conclusion was that deinit()
should not be relied on for such things. The Swift book seems to suggest it can nonetheless. If a new development comes along, we can look at this again. But it probably wouldn't be worth the performance trade-off anyway.
deinit
's behaviournil
(no refs). Don't want to have to manually set it once done (might as well useclose()
). Neither do we want to use optional binding (it's a long lived object, gets repetitive). Want to use an implicitly unwrapped optional (due to the failableinit()
), but thendeinit
doesn't get called