Re:C++17’s Useful Features for Embedded Systems
by jnwatson on Monday May 29, 2023 @03:13PM
(#36116979)
Rust. The alternative is Rust.
[ Parent
| on HN ]
Re:C++17’s Useful Features for Embedded Systems
by nuancebydefault on Monday May 29, 2023 @03:54PM
(#36117402)
I hope you will be proven right!
Re:C++17’s Useful Features for Embedded Systems
by GuB-42 on Monday May 29, 2023 @08:57PM
(#36119997)
I don't think Rust has an equivalent to C++17 constexpr, it is more limited.
Zig may be a better option when it comes to compile-time evaluation.
Re:C++17’s Useful Features for Embedded Systems
by pie_flavor on Monday May 29, 2023 @09:50PM
(#36120317)
The `if` part of the quoted example, you can do in Rust; the `else` part is coming with the specialization feature soon. Everything you can't do with traits, including specialization, you should probably not be doing; modern C++ tends to be an incomprehensible template forest.