Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
dthul
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
20 ms
·
121.
▲
by
dthul
6y ago
On some websites I get a tracking / cookie consent popup which, if I choose not to consent to everything, leaves me hanging for a _very_ long time while "saving my settings". I am talking about 30-60 seconds here. That must b
122.
▲
by
dthul
6y ago
It is indeed a bit unhinged. It seems they just measured the diameter of the holes and then formed a series of integer multiples of these measurements. And some of these multiples happen to coincide with numbers used in specific settings (n
123.
▲
by
dthul
6y ago
Same for me, the trackpad is the main reason I don't want to switch away from Macbooks. It's just unreasonably good. I fear that the amount of software and hardware integration required to get to this level is so high the we will
124.
▲
by
dthul
6y ago
I think it's a neat approach for low-budget sports broadcasting but not very novel. Computer vision master students have been implementing ball tracking algorithms in first year courses since years. You usually combine some kind of fea
125.
▲
by
dthul
6y ago
I think it refers to the fact that in an immediate mode GUI you adjust the application state while you render the page, meaning that the part of the screen which you rendered before the state was updated shows the old state, while the part
126.
▲
by
dthul
6y ago
Is that an auto-generated comment? I can't make sense of it at all.
127.
▲
by
dthul
6y ago
They closed a loophole that allowed proprietary modules to access GPL only functionality.
128.
▲
by
dthul
6y ago
Oh wow, "much less hostile than reddit"? I already regret visiting that site after a minute. Almost all of the current front page posts are either covid denial or bashing black people.
129.
▲
by
dthul
6y ago
There is no roadmap yet. This is a call for input.
130.
▲
by
dthul
6y ago
I also fell for Adobe's "monthly subscription". The only saving grace was that I by chance happened to cancel 11 months in, only to be suprised that I actually was on a yearly subscription. Lost one month of fees, could have
131.
▲
by
dthul
6y ago
In Quantum computers, bits (called qubits) can be in a superposition, not just binary 0 or 1. IBM has a nice introduction: https://quantum-computing.ibm.com/docs/iqx/guide/
132.
▲
by
dthul
6y ago
Elm really is a gem. It's like an "approachable browser Haskell". And the Elm Architecture makes it really easy and fun to handle your state and the view(s) into it.
133.
▲
by
dthul
6y ago
Someone on Twitter mentioned Servo's "Layout 2020" project which would have ensured that Firefox's layout engine stays competitive: https://github.com/servo/servo/wiki/Layout-2020
134.
▲
by
dthul
6y ago
You can! println!("{a} {c} {b}", a="a", b='b', c=3); // => "a 3 b"
135.
▲
by
dthul
6y ago
Yes, they make solving such problems quite elegant. The Wikipedia page on variadic templates has a toy printf C++ implementation showcasing that.
136.
▲
by
dthul
6y ago
The position of arguments is actually not required to follow the format string. From the documentation: println!("{1} {} {0} {}", 1, 2); // => "2 1 1 2" But you are right, you cannot dynamically chang
137.
▲
by
dthul
6y ago
That's actually very similar to Rust, where println is also type safe. Depending on the format string it uses different traits to print each value. For example the format specifier "{}" will use the value's "Display
138.
▲
by
dthul
6y ago
Neither in Rust ;)
139.
▲
by
dthul
6y ago
I didn't know that it was possible to export Rust enums with a C ABI like that, that's nifty!
140.
▲
by
dthul
6y ago
There are no good alternatives in Typescript. Nobody claimed that there are no other languages with enums.
141.
▲
by
dthul
6y ago
In a parallel thread someone mentioned that Maven allows you to obtain a "com.github.username" namespace based on your Github account, which is already a requirement to publish on crates.io anyway.
142.
▲
by
dthul
6y ago
My initial concern was that a DNS approach would force anybody who wanted to publish to crates.io to own a domain. In a parallel thread someone mentioned that Maven allows to acquire a "com.github.username" namespace in case you d
143.
▲
by
dthul
6y ago
I don't know Maven much so please correct me if I'm wrong, but I believe there is a substantial difference: In Maven anybody could publish a package that starts with "com.google". The namespacing proposals I have seen fo
144.
▲
by
dthul
6y ago
If we really wanted, Cargo could start supporting namespaces and everything currently on crates.io could go to a new default namespace (and would still be reachable under the non-namespaced name for older versions of Cargo). I don't th
145.
▲
by
dthul
6y ago
While technically true, the documentation makes it very clear that Deref should only be implemented for smart pointers and never fail. So no allocations in practice.
146.
▲
by
dthul
6y ago
Not in practice. It's only used for reference coercions to existing objects. You would need to ignore the documentation and bend over backwards to use it for an actual type conversion, because you can only return references.
147.
▲
by
dthul
6y ago
Rust does not have implicit type conversions.
148.
▲
by
dthul
6y ago
True, those are even more places where C++ can implicitly allocate. The operator overloading also applies to Rust. Rust has no implicit conversions though, which are arguably worse since they are invisible (that's why I usually mark al
149.
▲
by
dthul
6y ago
Just one or two days ago I asked here on HN how memory allocations in C++ are considered to be more hidden than in Rust and got some good replies: Especially constructors, copy constructors, assignment operators etc. can introduce non-obvio
150.
▲
by
dthul
6y ago
Yeah, maybe he was referring to constructors. That might make sense, since something like "MyType t;" could allocate. I guess in the kernel context the STL (or whatever was around in 1992) would not be used though. Edit: or even s
More ›