Maybe someday it'll be rust, but if so that day isn't this year or next. Plenty of time to pick it up for your next job.
Ask HN: Rust or C or C++ in 2023?
21–30 of 56 posts
Re: Ask HN: Rust or C or C++ in 2023?
#22Re: Ask HN: Rust or C or C++ in 2023?
#23The key to any of embedded, system, or low-level programming is as much about learning how the computer actually works to a reasonable degree. You are not programming to an abstract computation model. You are moving bits and bytes around and generating assembly code and talking to the machine at quite a low-level . So while Rust and C++ are higher-level languages with all kinds of nice features to be safer, concise,…
Re: Ask HN: Rust or C or C++ in 2023?
#24cpp feels better to me now, but that could easily change.
rust-analyzer is a good experience, and cpp is not exactly fast, just faster.
Re: Ask HN: Rust or C or C++ in 2023?
#25It offers the same system programming capabilities as C but makes it much easier to write correct programs.
(If Rust is the “better C++”, then Zig is the “better C”).
Re: Ask HN: Rust or C or C++ in 2023?
#26The key to any of embedded, system, or low-level programming is as much about learning how the computer actually works to a reasonable degree. You are not programming to an abstract computation model. You are moving bits and bytes around and generating assembly code and talking to the machine at quite a low-level . So while Rust and C++ are higher-level languages with all kinds of nice features to be safer, concise,…
passing structs to functions is probably the way, but a struct with functions works too.
Re: Ask HN: Rust or C or C++ in 2023?
#27C is such a glorious language to competently develop software in, UB be damned.
Re: Ask HN: Rust or C or C++ in 2023?
#28Learn enough C to encounter the pain points C++ & Rust are trying to solve. C is simple, but not easy. Then learn enough Rust to be productive. Then learn enough C++ to interact with the enormous amounts of existing C++ code. Once you know a bit of all 3, decide where to focus based on the work you're trying to do. Rust is the easiest, but least widely supported. C is necessary either way, unless you're working for M…
> C is simple, but not easy. I think I know what you're trying to say, but unfortunately C is anything but simple. The semantics are riddled with surprises of all kinds. It's unlikely the average C programmer has never written a program with undefined behavior, for example.
Re: Ask HN: Rust or C or C++ in 2023?
#29C is the best choice to learn systems programming. C is the simplest of C, C++, or Rust and most other languages have C interop or foreign function interface. First learn C and then you can learn Rust or C++ if needed. The concepts you learn in C programming will help you to better understand the more advanced concepts used in Rust or C++. Recommended first book: https://en.wikipedia.org/wiki/The_C_Programming_Langua…
The rust programmers that learned C first always have very elegant solutions and have the least issues in their unsafe blocks.
C to learn how memory works and how to manage resources, then Rust to understand how to use a higher level systems language for more productivity in places where it helps.
I work as a C++ dev and there are jobs in it, but unless you are trying to work a C++ job, the other two are wayyy better.
Re: Ask HN: Rust or C or C++ in 2023?
#30Learn enough C to encounter the pain points C++ & Rust are trying to solve. C is simple, but not easy. Then learn enough Rust to be productive. Then learn enough C++ to interact with the enormous amounts of existing C++ code. Once you know a bit of all 3, decide where to focus based on the work you're trying to do. Rust is the easiest, but least widely supported. C is necessary either way, unless you're working for M…
> C is simple, but not easy. I think I know what you're trying to say, but unfortunately C is anything but simple. The semantics are riddled with surprises of all kinds. It's unlikely the average C programmer has never written a program with undefined behavior, for example.
Rust hurts when you're learning it. C hurts when you're trying to debug your program.
If you've never written low level code before, I wouldn't start with rust. Zig or C are both much better options when getting started. But learning rust eventually will make you a better programmer.