Better HN
topnewbestaskshowjobs
Log inSign up

gilnaa

66 karma · joined Mar 10, 2018 (8y ago) · 34 submissions

Submissions

comment 2y ago · link · parent

Like an onion

comment 3y ago · link · parent

Polars is already not python

comment 3y ago · link · parent

EDITOR=true is clever! Git has --no-edit as well, btw

comment 4y ago · link · parent

Panics _can_ sometimes conceptually share the same implementation as exceptions, but given that their usage is not the same, and the fact that the ecosystem doesn't use panics as exceptions, it's a bit of stretch saying they're "functionally" the same.

A bit like saying trains and chairs are functionally the same since they both can have wheels; when there's the crucial difference that chairs don't go choo-choo.

comment 4y ago · link · parent

Isn't this why Windows have MOV EDI, EDI at the start of a function? https://devblogs.microsoft.com/oldnewthing/20110921-00/?p=95...

comment 4y ago · link · parent

"I want X" "Here's Y" "Yeah no"

comment 4y ago · link · parent

Not to mention that it didn't even get into C++

comment 4y ago · link · parent

You put #[non_exhaustive] on a enum in Rust to force users matching on it to handle an "else"/"default" case, so that you can add more variants to this enum in the future without breaking their code.

It doesn't mean that the enum itself is non exhaustive: at any point in time when enum is defined, it defines all of its variants and any other value is still UB.

comment 4y ago · link · parent

It's not that it is unstable as much as it is needlessly painful to work with.

comment 5y ago · link · parent

56GiB/s*

11.

How to FizzBuzz at 40GiB/S(codegolf.stackexchange.com ↗)

6 points · by gilnaa · 5y ago · 2 comments

comment 5y ago · link · parent

a tool doesn't have to be a clean room implementation to be useful

comment 5y ago · link · parent

Sorry to hear that

comment 5y ago · link · parent

Not to sound too aggressive, I'm not sure why ada programmers keep being surprised at the hype.

Safety (of all kinds) is not the only selling point of Rust and Zig, and the fact that Ada also have safety measures doesn't mean that it's instantly an option for me.

For example, I keep seeing people hype about Zig/Rust, for all kinds of reasons; and the way that they present their arguments is very compelling. While I've heard of Ada before, AFAICT the only context in which it is brought up is to downplay hype over Rust/Zig; never as a standalone.

Sounds like a PR problem, mostly.

EDIT: Not to say that there aren't other problems, just saying that this point alone isn't some magic bullet.

I don't like Rust because it gives me memory safety, tons of languages do that. I love Rust because the tradeoffs it gives me worth the switch, and the overall tooling and ecosystem are very well made.

comment 5y ago · link · parent

Great work!

"Allocate T bytes on stack bound as x" may sound a bit like T is a size instead of a type.

comment 6y ago · link · parent

Hey, OP here. Code not written by me, but by a friend (iscgar) with no HN account.

On my late 2019 MacBook Pro, using clang 12.

    clang -O3 -march=native fizz4.c
    ./a.out | pv > /dev/null
Starts at around 4GiB/s and drops down to 3.8 after a while, probably due to battery/heating.

17.

Show HN: FizzBuzz 4GiB/S(gist.github.com ↗)

4 points · by gilnaa · 6y ago · 1 comment

comment 6y ago · link · parent

I was quite surprised to read that you can't set a custom hasher in C++/Rust, and I even went and made sure that it's possible.

But then I re-read your comment and realized you've meant that you can't do this in JS.

comment 6y ago · link · parent

I think he refers to the ligatures

comment 6y ago · link · parent

Wow, Banshee. I liked it so much and no other player managed to replace it for me.

What a shame that it died.

comment 6y ago · link · parent

List of bugs fixed in 9.3:

https://gcc.gnu.org/bugzilla/buglist.cgi?bug_status=RESOLVED...

comment 6y ago · link · parent

But is mostly unused and mostly irrelevant

comment 7y ago · link · parent

But they do make it, present tense.

comment 7y ago · link · parent

Roof-installed consumer-grade nuclear reactors

comment 7y ago · link · parent

It's not always up to me which compiler version I use.

Some organizations change compilers very slowly, and you can't assume you always have the most updated compiler.

For example, when writing a library for my org I assumed that GCC 5.4 (2016) is a reasonable lower bound, and I used the appropriate set of supported C++11 features, and twice I had to downgrade as different teams notified me they had older and older compilers. (and couldn't upgrade)

comment 8y ago · link · parent

HaArtez has a pawywall, which is unfortunate.

This industry seem to be comprised of morally bankrupt executives and that's a shame.

The worst part is that Tamar Zandberg, a leftist party leader, tried to get some of the companies' export license revoked, but the government flat out refused, saying that the export tax is prioritized higher than human rights violations.

comment 8y ago · link · parent

Very easy to blow up your stack with unsanitized input
12