Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
OskarS
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
41 ms
·
481.
▲
by
OskarS
5y ago
> With everything in the news about reproducibility and doctored data, this seems too staggering to believe. Has this study been tried again? Yep, totally! I'm a firm believer in the power of walking to increase thoughts, but whenev
482.
▲
by
OskarS
5y ago
Say you’re using the C API (not really relevant which language, any statically typed language would work) and had the line sqlite3_bind_int(stmt, 3, 45); to bind the value 45 to the third item in whatever INSERT/UPDATE statem
483.
▲
by
OskarS
5y ago
Clicking the link, I was kinda hoping it was some version of VFS for Git, but for operating systems other than Windows. Kinda bummed that it wasn't, this seems kinda pointless. Microsoft is (allegedly) working on macOS and Linux driver
484.
▲
by
OskarS
5y ago
I'm not sure I love this. I mean, LLVM is awesome and everthing, but software monocultures are pretty bad. It's not like the situation is dire yet (given that there are also GCC and MSVC), but you can imagine a situation in a coup
485.
▲
by
OskarS
5y ago
Ah, good point, I missed that my version became a tail call, good catch. Still, a C function call is pushing a couple of values onto the stack then performing an unconditional jump, so it's not much worse. That site is indeed very neat
486.
▲
by
OskarS
5y ago
> Doing a function call is quite expensive! Doing a function call in C/C++ is not expensive. I wish people would stop saying this, it's just not true, it's one of the most annoying myths in programming. A C function call i
487.
▲
by
OskarS
5y ago
The article deals with this in a later section and has an interesting discussion about the tradeoffs. Note that you don't have to ship Chromium with every app, you can also go use web rendering engines supplied by the platforms.
488.
▲
by
OskarS
5y ago
Just be careful to quote filename variables. Don't write this: cp $FILENAME $TARGET Write this: cp "$FILENAME" "$TARGET" It's a bit annoying, but it's not that bad, and certainly not unma
489.
▲
by
OskarS
5y ago
I see that point, but it was pretty jarring reading this Elixir article as a curious outsider that they had to make these kinds of very advanced contortions to do something so simple in such a non-performant way. It’s something that is only
490.
▲
by
OskarS
5y ago
I think Erlang and Elixir are incredible, and this particular feature of libraries starting BEAM processes seems cool in the abstract. However, this PARTICULAR task, Erlang/Elixir might be the worst possible language you could choose:
491.
▲
by
OskarS
5y ago
And the first argument to printf (the format), what kind of string is that? And what kind of string does sprintf() produce?
492.
▲
by
OskarS
5y ago
I haven’t seen the movie so I have no idea, but I can’t but quote from the article itself: “..is the character based on me actually innocent? Turns out, she asked the killer to help her get rid of her roommate. She didn’t mean for him to
493.
▲
by
OskarS
5y ago
It’s a really powerful article, and it’s hard to argue with any of it. What a nightmare it must be to have what happened to Amanda Knox happen to you. A totally innocent person, who was not only imprisoned for years for a crime she had noth
494.
▲
by
OskarS
5y ago
It’s also, like, trivial: as far as I can tell, this is just a very basic description of how a call stack works mixed in with advertising calls to action.
495.
▲
by
OskarS
5y ago
The whole point of the article is that the optimizer in GCC did not do this.
496.
▲
by
OskarS
5y ago
Nice article! This sort of code is not just used in databases, it's also obviously the "merge" step in mergesort. The fact that you have to "lure" the compiler into making the hot loop branchless is a little bit wei
497.
▲
by
OskarS
5y ago
You’re probably thinking of C/C++ unions, and they do indeed have quite tricky semantics and are difficult to use correctly. What the article and the other commentators are talking about is more properly called a “sum type”, like Rust’
498.
▲
Dancing links – Donald Knuth (2000) [pdf]
(arxiv.org)
1 points
by
OskarS
5y ago
|
0 comments
499.
▲
by
OskarS
5y ago
Enough people rely on debit cards nowadays that only work online that it would still cause significant disruption. Enough that it's probably not worth keeping the stores open until it can be fixed.
500.
▲
by
OskarS
5y ago
Going cashless is extremely common for customers in Sweden. They would get so few customers (everyone would just go to the next grocery store), and the aggravation it would cause from customers who haven't heard the news and can't
501.
▲
by
OskarS
5y ago
> Yes but how does the cashier know what the price is? My understanding was that it was just payment processing that was affected, not the point of sale systems. The scanners and things probably work fine, and I think they could accept c
502.
▲
by
OskarS
5y ago
I think that this is the case, from the reporting it seems like it’s just their payment infrastructure that is affected. Likely they could handle cash transactions just fine. It’s just that the vast, vast majority of Swedish customers don’
503.
▲
by
OskarS
5y ago
You're not wrong, but the very idea that it will regurgitate copyrighted code at all (and especially at this length, word for word), means that it will be totally unacceptable for many places. In fact, it is arguably not acceptable t
504.
▲
by
OskarS
5y ago
Apparently Carmack was not the original author, the origin I believe is SGI somewhere in the deep dark 90s.
505.
▲
by
OskarS
5y ago
This is for, like, debug purposes. Makes logs and things like JSON requests easier to read because the output matches the source. Logically though, they are still unordered for things like equivalence checks, so those two examples you had t
506.
▲
by
OskarS
5y ago
> Javascript JITs are really good, you (likely) aren't going to see major performance improvements by dropping into WASM. A javascript JIT is never going to be able to compete with codegen from a low-level statically typed language
507.
▲
by
OskarS
5y ago
> It doesn't Yes it does. Of course you can detect different evaluation orders using side effects, but the fact that evaluation order is unspecified isn't generally a problem: if you write code like `a() + b()` and a() and b()
508.
▲
by
OskarS
5y ago
It's standard usage at this point, adding a [sic] would not be correct. You should climb down from this hill.
509.
▲
by
OskarS
5y ago
If you're prepared to commit criminal tax fraud, there are many better ways you can earn money.
510.
▲
by
OskarS
5y ago
You’re right, there’s nothing inherently wrong with map, reduce and the rest of the high-order functional suite. What I’m talking about more is when people make very complicated aggregation functions in order to keep state around. In these
More ›