Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
identity0
searching Neon…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
7 ms
·
1.
▲
by
identity0
6y ago
SVG is still a stupid format. Who wants to send image data through XML? It would be like sending a raster image through a big JSON array.
2.
▲
by
identity0
6y ago
>There are two main solutions: Use an option or maybe type or Use a nullable type I don't get it. These are literally all exactly the same thing, all slightly varying in ergonomics and compiler support. They may differ slightly but
3.
▲
by
identity0
6y ago
When I click a link, I want to know where I'm going. Where do you think "arewesmoothyet.com" will take you? If you guessed some Mozilla related thing purely from context, well you're also wrong. It's actually some W
4.
▲
by
identity0
6y ago
Well "next_ptr" is also a bad name, I agree, but I'm trying to name it something that indicates "this is a pointer to the 'next' pointer in the linked list".
5.
▲
by
identity0
6y ago
What a waste of domain space (yes, I know they're abundant, but still.) areweaudioyet.com says nothing about its contents. areweasyncyet.rs had the right idea with the .rs domain name, but anyways, I feel like all of these would be bet
6.
▲
by
identity0
6y ago
The top pattern is extremely common so comments are somewhat unnecessary since everyone would know what you're doing. In the second one, comments would be less necessary with a type annotation and perhaps a better name. Maybe "nex
7.
▲
by
identity0
6y ago
auto in function signatures is just really, really stupid.
8.
▲
by
identity0
6y ago
I'm not so sure about that. Surely it would take longer to parse both branches of an if-constexpr then it would for the preprocessor to see the #if and discard half of it.
9.
▲
by
identity0
6y ago
I wish more languages gave us a "|>" operator. Too many languages settle with dot notation, which confuses encapsulation/method calling with syntactical convenience.
10.
▲
by
identity0
6y ago
I remember implementing the comment collapsing thing without JS, you have the "[-]" be a label for a checkbox button, and then you just use CSS to hide the sections for which the checkbox is checked.
11.
▲
by
identity0
6y ago
That's true, it's more like naming your language "BlockchainScript". I could totally see someone doing that today.
12.
▲
by
identity0
6y ago
Oh come on, don't be pedantic. There is a term for non-physically-based rendered, it's called "rasterization". Just because it's technically incorrect doesn't mean it's any less of a colloquial term. To ig
13.
▲
by
identity0
6y ago
Agreed. It's not a "foreign" function if everything is in WASM. All the VM sees is WASM code; it doesn't make a difference if it was originally written in C or Rust.
14.
▲
by
identity0
6y ago
Ok.
15.
▲
by
identity0
6y ago
hCaptcha works on Tor, sometimes.
16.
▲
by
identity0
6y ago
Have you ever seen a procedural language with a good REPL? Python maybe, but definitely no compiled procedural garbage-collectorless language. The "needing to put type signatures" is completely unrelated. I have no idea how that w
17.
▲
by
identity0
6y ago
You mean like a REPL? Most languages are unusable for interactive programming. And it's not a downside if it stops use in a domain that was nobody's goal.
18.
▲
by
identity0
6y ago
Threes made the fatal mistake of charging money on the App Store.
19.
▲
by
identity0
6y ago
One ugly trick for unreachable branches is this: assert(!"You gave an invalid letter"); The string literal is a pointer, so !pointer is false. And then you get a nice explanation message when the assertion fails. I wish a
20.
▲
by
identity0
6y ago
I would recommend not doing that. Just use the initializer syntax, or write an inline function.
21.
▲
by
identity0
6y ago
-Wimplicit, UBSan, ASan,... The idea that "you can't write safe C" is a big joke. C is as safe as you make it.
22.
▲
by
identity0
6y ago
I have never seen a well-made but general solution beat a well-made and specific solution for one problem, in complexity or run time, ever. This is very true with allocators. A lot of the time people will just use 'malloc' without
23.
▲
by
identity0
6y ago
I believe calling C from Go is a massive pain, and is slow, because of goroutines. Go makes the OS syscalls directly to avoid going through libc.
24.
▲
by
identity0
6y ago
Allocation logic is much simpler than you think. A solution to a specific problem will always be simpler and faster than a general solution like jemalloc.
25.
▲
by
identity0
6y ago
At this point, why not just use C?
26.
▲
by
identity0
6y ago
In vim if you press K it will bring up the man page for the word under your cursor. It was very useful when learning C, considering that most libc functions have helpful man pages.
27.
▲
by
identity0
6y ago
It's not that GNU is incompetent or overly bureaucratic or anything. It's that they really didn't want to infringe on Unix, and they presumed that Unix's yes would have been implemented in the most obvious, dead-simple w
28.
▲
by
identity0
6y ago
This is why grammar is not optional. I have no clue what you said or are trying to convey. Yeah english is flexible, but that doesn't mean you can just drop articles and sentence structure.
29.
▲
by
identity0
6y ago
And that's why I don't like this concept. Let's be honest, that passage sounds like crap. I'm all for brevity, and I think nowadays people tend to write with too much formality and bureaucracy, but this app is not the wa
30.
▲
by
identity0
6y ago
Not sure what your point is. 1. Because it's healthy and feels good 2. Because it's healthy and may stop future problems 3. Because it may stop future problems 4. Because it feels good So why lose weight for the sake of losing wei
More ›