Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
EPWN3D
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
6 ms
·
61.
▲
by
EPWN3D
5mo ago
This is a tragically misguided view. There are tons of code bases that aren't going to be rewritten in safe languages for various reasons, be it political or technical. You may or may not agree with those reasons, and you may or may no
62.
▲
by
EPWN3D
5mo ago
I just haven't tried it on a BSD. No reason it wouldn't work though. Might require a couple of fixes here and there, but generally the library sticks to standard C stuff and uncontroversial POSIX (in the POSIX target).
63.
▲
by
EPWN3D
5mo ago
There are people on my team who are interested in stewarding, so I think it'll be covered.
64.
▲
by
EPWN3D
5mo ago
C does not need to be completely safe. But it should be safer by default than it currently is. And I think that "it's a low level language, you just need to be smarter" is too often a cover story for bad design decisions. I d
65.
▲
by
EPWN3D
5mo ago
Yeah here's a trivial one. void *__free p = NULL; func(&p); // func zeroes p to claim ownership // end of scope, p is NULL, nothing happens // if func was not called, p is freed
66.
▲
by
EPWN3D
5mo ago
I'll have to give the access attributes a look, I hadn't heard of them. (My team were sitting back on gcc-12, so not up to speed on the latest.) I think I had seen noplate before -- looks like you're taking advantage of the a
67.
▲
by
EPWN3D
5mo ago
Microsoft supports memory safety. Rust is 100% the direction for new projects. But there are existing C codebases that are unlikely to be entirely rewritten in a memory-safe language for various reasons. Such projects can significantly bene
68.
▲
by
EPWN3D
5mo ago
I think the real failing is that new language features then must be prototyped by people who have a background in compilers . That's a very small subset of the overall C community. I don't have any clue how to patch clang's
69.
▲
by
EPWN3D
5mo ago
Thanks! I agree, a better build story for C projects is desperately needed.
70.
▲
by
EPWN3D
5mo ago
I think defer has been included in the next round of working group proposals for C2y, but I don't think Apple's clang has it. Maybe it's there as a language extension and I just didn't see it. What lib0xc has is some cle
71.
▲
by
EPWN3D
5mo ago
Not really. You'd still be able to address memory as bytes. The problem with void * is that it strips all bounds information by its nature. Most of the time when you're passing a void * without an associated length (e.g. context p
72.
▲
by
EPWN3D
5mo ago
It's designed to be incremental. For example, you can do a search for `sprintf` and replace it with `ssprintf`. The function signature is the same. Any instance of printing to a character array just works. Think of the APIs as "th
73.
▲
by
EPWN3D
5mo ago
> This might be a dumb question, but using this + clang bounds-safety, whats the difference between this and something like Zig or Odin. I really need to learn more about Zig, but from what I know, there are still worlds of possibilities
74.
▲
by
EPWN3D
5mo ago
Author here, I posted this in Show HN but someone clearly beat me to it. So I'll repost my blurb from there. Various patterns for safer C programming have been cargo-culting around the industry for decades. Because the language evolves
75.
▲
by
EPWN3D
5mo ago
Haven't really verified that it works with C++, but I tried my best to guard the stuff I knew would be problematic with #if __cplusplus. Happy to have a PR that makes C++ happier with it.
76.
▲
by
EPWN3D
5mo ago
Author here. It is not currently in production, but it is part of a project in Azure which will go to production at some point. I'm actually leaving Microsoft next week and fully intend to keep working on it if I can reach an agreement
77.
▲
Show HN: Lib0xc, the C standard library you wish you had
(github.com)
1 points
by
EPWN3D
5mo ago
|
0 comments
78.
▲
by
EPWN3D
6mo ago
That's not apples to apples due to Microsoft's massive force reductions and Azure's massive growth.
79.
▲
by
EPWN3D
6mo ago
The average user cares about their fans going full-blast when running some garbage electron app and their battery life being shit. You're just being dense.
80.
▲
by
EPWN3D
6mo ago
The only changes I'd want to Markdown: - Reverse the link syntax braces, so the URL is in [], and the link text is in () - Allow table cell content to have line continuations
81.
▲
by
EPWN3D
6mo ago
I mostly agree, but network byte ordering is still a thing.
82.
▲
by
EPWN3D
6mo ago
The various "OMG MICROPLASTICS" studies always smacked of alarmism. No one has actually identified tangible harms from microplastics; it's just taken as a given that they are bad. So this fueled a bunch of studies that tried
83.
▲
by
EPWN3D
7mo ago
He shows no remorse for any innocent lives lost during these operations. He emphasizes that the "minimum" number of innocent deaths has been achieved, and for him, that's job done. You can accept that warfare is sometimes nec
84.
▲
by
EPWN3D
7mo ago
> Modern kernel anti-cheat systems are, without exaggeration, among the most sophisticated pieces of software running on consumer Windows machines. They operate at the highest privilege level available to software, they intercept kernel
85.
▲
by
EPWN3D
7mo ago
That's not true at all. I don't like HR departments, and I think they're the scum of the corporate world, especially the latest batch of HR geniuses to slither out of whatever business school swamp spawns them. But their job
86.
▲
by
EPWN3D
7mo ago
I don't think you know what security by obscurity is.
87.
▲
by
EPWN3D
7mo ago
There are some people who just have high cholesterol but none of the other risk factors. I'm one of them. I did a calcium score on my heart, and it came back clean. The cardiologist basically said my cholesterol is just part of who I a
88.
▲
by
EPWN3D
7mo ago
I wonder, do overnight oats wind up processing away a lot of the benefits? Do steel-cut oats have more of an effect on cholesterol than rolled?
89.
▲
by
EPWN3D
7mo ago
> One, the article asserts that too many stops is the main cause of low ridership in the US. That's not what I read. The article is saying that you can get meaningful service improvements via what is essentially a free measure: cutt
90.
▲
by
EPWN3D
8mo ago
Had the exact same reaction to that exact scene. Just couldn't get past it. It wasn't as bad as when I tried to watch Big Bang Theory (which multiple people assured me that I'd love), but it was in that ballpark.
More ›