logoalt Hacker News

Panzerschrekyesterday at 6:41 AM1 replyview on HN

> If I wanted working really close to hardware, do bit-twiddling and knowing where every byte is allocated, I'd take Zig

Why not C++? It allows as many low-level operations as one wishes, but don't forces you to manage memory manually where it isn't necessary.

> If I wanted to write a small piece of code intended to run absolutely everywhere

GCC and Clang have support of C++ since many years. Is there any modern platform for which no GCC or Clang backend exist?


Replies

nine_kyesterday at 9:51 PM

Why not C++: build system(s), stdlib, modularity (though C++20 has modules, who uses them?), presence of UD. Better languages don't carry the unfortunate baggage of 1970s which C++ needs to be compatible with.