I used it when I wrote some throwaway C++ code working with SQLite. Since it had no RAII (and I had no intention of writing my own wrapper), I had to manually cleanup multiple resources somehow. If at least one resource failed to initialize, I had to deinitialize the ones that didn't fail. It was either goto or a bunch of flags to track what is initialized. goto looked more elegant.
First time I'm hearing of the CQS. Wow, just wow. Dystopian shit.
New account experience on Reddit in 2025:
Create an account;
Post something on a subreddit that has AutoMod configured to instantly remove posts/comments from new accounts, accounts with low karma or accounts with low CQS;
Get a site-wide shadowban because your first contribution was removed;
If you're unaware of shadowbans, keep using the site, leaving comments, thinking nobody replies to you because you're not that interesting;
If you're aware of them, keep trying to appeal with zero effect.
Fuck Steve Huffman and fuck his enshittified site.
It does make sense, if you skim through the research paper (page 11). They aren't using performance.now() or whatever the state-of-the-art in JS currently is. Their measurements include invocation of the interpreter. And parsing TS involves bigger overhead than parsing JS.
I assume (didn't read the whole paper, honestly DGAF) they don't do that with compiled languages, because there's no way the gap between compiling C and Rust or C++ is that small.
I mean, in C too.
I used it when I wrote some throwaway C++ code working with SQLite. Since it had no RAII (and I had no intention of writing my own wrapper), I had to manually cleanup multiple resources somehow. If at least one resource failed to initialize, I had to deinitialize the ones that didn't fail. It was either
gotoor a bunch of flags to track what is initialized.gotolooked more elegant.