2035 came early (opens external site)
View full thread · View on Hacker News
To get push notifications on iPhone or iPad, add Hack and Chat to your Home Screen: tap Share → Add to Home Screen, then open the installed app and enable push in Settings.
View full thread · View on Hacker News
Replies (1)
In any case, you have two ways to do something similar, kind of.
Naturally there are multiple variations thereof, on how to handle errors, or which way to parameterise how to close resources.Then we have the C# inspired way,
And if open_resouce doesn't support using declaration, an helper builder function can be used to wrap it in such a type.Yes it isn't as automatic as pure RAII, but it gets close enough for most practical purposes.
Replies (2)
Replies (1)
Which besides not having global variables, also don't do continue, break, return.
The first approach traces back to how resource management was initially done in Lisp languages, alongside conditions.
Replies (1)