Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
davemp
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
9 ms
·
91.
▲
by
davemp
1y ago
Yeah I don’t think 30ms is very noticeable, but say you have a cli tool with other 20-70ms to bump you up to 50-100ms your tool will have noticeable latency. Death by a thousand cuts.
92.
▲
by
davemp
1y ago
No, the solutions I spoke about were language features that make it trivial to avoid or impossible to make the mistakes. If your bar for mistakes is “what if you forget to add literally the next line of code in the incredibly common pattern
93.
▲
by
davemp
1y ago
I literally replied with “A Way to Prevent This”?
94.
▲
by
davemp
1y ago
Nothing can prevent a sufficiently belligerent programmer from writing bad code. Not even Rust—which I assume you’re advocating for without reading the greater context of this thread.
95.
▲
by
davemp
1y ago
Judging from the article, Zig would have prevented the CVE. > This includes memory allocations of type NV01_MEMORY_DEVICELESS which are not associated with any device and therefore have the pGpu field of their corresponding MEMORY_DESCRI
96.
▲
by
davemp
1y ago
It’s semantics. Zig can still have dangling references/uaf. You can do something like ‘var foo: *Bar = @intToPtr(0x00)’ but in order to “properly” use the zero address to represent state you have to use ‘var foo: ?*Bar = null’ which is
97.
▲
by
davemp
1y ago
30ms is pretty close to noticeable for anything that responds to user input. 30ms startup + 20-70ms processing would probably bump you into the noticeable latency range.
98.
▲
by
davemp
1y ago
Water attenuates (reduces the power of) signals significantly and more-so at higher frequencies. The HF (3-30MHz) band is definitely not what you’d want to pick (sonar is in the KHz range). The sub was probably still 27MHz but just higher p
99.
▲
by
davemp
1y ago
Technically but I don’t think folks ever really bothered.
100.
▲
by
davemp
1y ago
I’m still regularly getting on projects and moving C89 variable declarations from the start of functions to where they’re initialized, but I guess it’s not the kids doing it.
101.
▲
by
davemp
1y ago
> property of software being verifiable Software is verifiable given a specific test oracle. There are however many problems where providing a correct test oracle is at least as hard as solving the problem itself. If you’ve ever worked o
102.
▲
by
davemp
1y ago
I’ve always assumed it’s a long term goal for total DRM
103.
▲
by
davemp
1y ago
There are levels here, Zig addresses: - out of bounds access (70% of CVEs) - nullptr dereferences - type safety issues That’s massively better than C. Preventing use after free errors requires much less discipline than never missing a bound
104.
▲
by
davemp
1y ago
I’ve been using it for an embedded project to target arm thumb and the typical x86-64 hosts that communicate with a protobuf based protocol. It’s absurdly convenient to be able to just give windows users the repo, zig binary, and tell them
105.
▲
by
davemp
1y ago
I had a curved ultrawide for a while, and didn’t have many complaints. But I switched to a 32” 16:9 and 24” 16:9 portrait and wouldn’t go back. I’ve found having extra vertical space to be really nice and that window managers are easier to
106.
▲
by
davemp
1y ago
Or you know Linux/Windows PCs that would definitely be a big win.
107.
▲
by
davemp
1y ago
I’m only found them to be useful in gargantuan OOP piles where the context is really hard to keep in your head and getting to any given point in execution can take minutes. In those cases interactive debugging has been invaluable.
108.
▲
by
davemp
1y ago
I prefer it as long as there’s no side effects. You get tighter semantics which I think helps readability (and I trust compilers to be able to handle it optimally). I find the following format to be very nice: value = (condition)
109.
▲
by
davemp
1y ago
Zig is not a hobby project. > It doesn't address the problems people actually have with C++, not like Rust or Swift do Speak for yourself. Zig addresses pretty much all of my problems with C++: - terrible compile times - overly comp
110.
▲
by
davemp
1y ago
> A top tier human driver in the top shape outperforms this generation of car AIs. Most non-impaired humans outperform the current gen. The study I saw had FSD at 10x fatalities per mile vs non-impaired drivers.
111.
▲
by
davemp
1y ago
> To privatize something implies motion from public to private. Only if you’re being pedantic. Taking on the responsibility to raise children will completely take over your life. Not even considering the financial cost of daycare or miss
112.
▲
by
davemp
1y ago
So much naivety. It’s like the new grad reading parts of a 500kloc project and proclaiming that it can only be saved by a full rewrite.
113.
▲
by
davemp
1y ago
That’s not really useful information. The nice thing about water is that it’s usually still water after it’s “used”. The question how much is used for mining slurry or chemical baths. Those 3000L/MWh might very well be more environment
114.
▲
by
davemp
1y ago
> It wasn't "sold" as though there were some cigarette smoking ad men behind it. There was a whole “Learn to Code” pitch from politicians saying that literally anyone could have a good job if only they learned to code.
115.
▲
by
davemp
1y ago
C23 is very different than C89. C89 variable declarations are decidedly not fun. Embed, designated initialization, and constexpr are really nice adds.
116.
▲
by
davemp
1y ago
Agreed. I’ve done a far bit of math in both and typst’s choices are way more memorable and ergonomic. It’s not like keeping the syntax would really gain typst anything besides folks not having learn new things.
117.
▲
by
davemp
1y ago
Thanks for the historical perspective. It probably was less of an issue on older hardware because you can ctrl-c if you’re IO starved. Linux user spaces do not do well when the OOM killer comes out to play. Personally, I don’t think these f
118.
▲
by
davemp
1y ago
There’s a difference between understanding your tool and unnecessary cognitive load. Make does not provide a sane way to run in parallel. You shouldn’t have to compose a command that parses /proc/cpuinfo to get the desired behavio
119.
▲
by
davemp
1y ago
The problem is ‘make -j’ spinning up 100s of C++ compilation jobs, using up all of the systems RAM+swap, and causing major instability. I get that the OS could mitigate this, but that’s often not an option in professional settings. The real
120.
▲
by
davemp
1y ago
NIST is supposed to serve this purpose but is very underfunded
More ›