Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
mrkeen
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
20 ms
·
361.
▲
by
mrkeen
10mo ago
Everything being passed by object reference just means every case is equally unclear. answer = frobnicate(foo) Will frobnicate destroy foo or not?
362.
▲
by
mrkeen
10mo ago
> You cherry picked a contrived example List.add is contrived? What are you doing that's simpler the list.add? > but that's one of the cleanest generics implementations. You're saying it's typically worse than thi
363.
▲
by
mrkeen
10mo ago
Then let me rephrase: If every iteration of a while-loop cost you a whole stack frame, then I'd be very rude about that language. This works, btw: #include <stdio.h> long calc_sum(int n, long acc) { return n == 0
364.
▲
by
mrkeen
10mo ago
Damn that's fast! I'm gonna stick my business logic in there instead.
365.
▲
by
mrkeen
10mo ago
It's not even that bad. As long as it's actual json, it doesn't matter if it's pretty-printed or not, since `jq` can fold and unfold it at will. I frequently fold logs into single lines, grep for something, then unfold t
366.
▲
by
mrkeen
10mo ago
Weird, that's exactly how I feel reading Go: func (lst *List[T]) Push(v T) { if lst.tail == nil { lst.head = &element[T]{val: v} lst.tail = lst.head } else { lst.tail.next = &element[T]{val:
367.
▲
by
mrkeen
10mo ago
Please, it supports a hole at best. Maybe a pit. No way will this let you construct an abyss.
368.
▲
by
mrkeen
10mo ago
Supporting recursion only to a depth of 1000 (or whatever) is equivalent to supporting loops of up to 1000 iterations. If I put out a language that crashed after 1000 iterations of a loop, I'd welcome the rudeness.
369.
▲
by
mrkeen
10mo ago
> You're also assuming your log infrastructure is a lot more durable than most are. Make actions, not assumptions. Instead of using a one machine storage system, distribute that storage across many machines. Then stop deleting the
370.
▲
by
mrkeen
10mo ago
> You're coupling logging with business logic Yes, the system shall not report that "User null was created" if it was actually "User 123 that was created". String? Not a chance, make a proper type-safe struct. U
371.
▲
by
mrkeen
10mo ago
> Your logs are lying to you. Not maliciously. They're just not equipped to tell the truth. The best way to equip logs to tell the truth is to have other parts of the system consume them as their source of truth. Firstly: "what
372.
▲
by
mrkeen
10mo ago
> Design decisions like write-ahead logs, large page sizes, and buffering table writes in bulk were built around disks where I/O was SLOW, and where sequential I/O was order(s)-of-magnitude faster than random. Overall speed is
373.
▲
by
mrkeen
10mo ago
Maybe it's more like being a taxi driver using a self-driving car.
374.
▲
by
mrkeen
10mo ago
You implemented Specifics. One of my pet-hates is fellow developers who call an implementation 'generic', but when you peek inside, there's just if-statements that (at best) cover the already-known input types. Usually I poin
375.
▲
by
mrkeen
10mo ago
I like it, but we'd need to find a new way to do auth (and then prevent that from being used for non-auth-related tracking)
376.
▲
by
mrkeen
10mo ago
I don't see most PRs because they happen in other teams, but I am part of Slack channel where there are too many "oops" messages for my liking. I.e. 1-2 times a month, there's an SQL script posted that will be run agains
377.
▲
by
mrkeen
10mo ago
Start with Wavelet trees (much more intuitive): https://www.alexbowe.com/wavelet-trees/ The matrix version is just an implementation detail to store the tree in a less tree-like shape so you don't need as many poi
378.
▲
by
mrkeen
10mo ago
> Can a wavelet be used with SIMD 128bit operations? Popcount works great in this context, but that only gives you linear speedups. Doing rank/select in O(1) instead of O(N) is a bigger win, and you get that by precomputing superbl
379.
▲
by
mrkeen
10mo ago
It's Strings. They go somewhere. The interface writes itself: Consumer<String>. At my absolute fanciest, I use a Queue, some terminal colouring, separate stderr from stdout, and write some short-hand functions (warn, err, info,
380.
▲
by
mrkeen
10mo ago
Because they have to be compatible with your logging implementation, and they were written first.
381.
▲
by
mrkeen
10mo ago
You're going to hate this thing called DNS
382.
▲
by
mrkeen
10mo ago
Someone mined Monero on my server a few years ago. I was running Jenkins.
383.
▲
by
mrkeen
10mo ago
What formal verification system did they use? Did they even execute it?
384.
▲
by
mrkeen
10mo ago
Not a chance. Apart from type-checking, all formal verification needs a human to invest time and thought. Fans of LLMs brag about speed and productivity .
385.
▲
by
mrkeen
10mo ago
Can TLA+ prove anything about something you specify but don't execute?
386.
▲
by
mrkeen
10mo ago
Here you go: https://news.ycombinator.com/item?id=46279123 [2025-12-10] > We generate every valid 7-digit North American phone number, then for every area code, send every number in batches of 40000 > Time to go do so
387.
▲
by
mrkeen
10mo ago
Yes, if you're in the group of developers who are passionate about db performance, but have ruled out the idea of spreading work out to multiple DBs, then continuing to use sequential IDs is fine.
388.
▲
by
mrkeen
10mo ago
If you have too many UUIDs, throw more DBs at the problem. Hopefully you haven't tied yourself to any architectural decisions that would limit you to only using a single database.
389.
▲
by
mrkeen
10mo ago
The 'collision' is two service classes both trying to use one db. If you separate them (i.e. microservices) the they no longer try to use one db.
390.
▲
by
mrkeen
10mo ago
Why compilers are hard – the IR data structure If you claim an IR makes things harder, just skip it. Compilers do have an essential complexity that makes them "hard" [...waffle waffle waffle...] The primary data [..
More ›