On Friday, 25 November 2016 at 10:14:46 UTC, Satoshi wrote:
but writing 20 times something like:
auto vi = (() @trusted => glXChooseXFBConfig(...))();

That's an anti-pattern and you should almost never actually do it. That is breaking the trusted thing, and is not what the blog means when it says keep the functions as small as possible.

just forced me to mark whole class with @trusted...

If the class encapsulates unsafe activity into some kind of safe interface, that's what you are *supposed* to do.

Reply via email to