3 ms·
> This is a common refrain in C++ testing: if it compiles then it's probably correct. I’ve heard this in Haskell and in Rust. I’ve never heard it applied to C+
by adastra22 3y ago
> This is a common refrain in C++ testing: if it compiles then it's probably correct.
I’ve heard this in Haskell and in Rust. I’ve never heard it applied to C++…
- ModernMech 3y agoI think they meant Rust? Rust definitely has that property to an extent; C++ is so far from it it’s not even funny.
- jeremyjh 3y agoI’ve definitely experienced it in Haskell and Rust. I can believe some C++ could be that way, but I’ve never experienced it, but then again those projects didn’t have useful tests either. I think with C++ a lot of this depends on domain and the quality of the code and libraries.
- xhainingx 3y agoIt's truer in C++ than java or similar languages ime since java relies more on exceptions, but it's certainly not as true as Haskell or rust
- Skunkleton 3y agoIs it true enough in c++ to be useful though?
- Capricorn2481 3y agoNo it isn't lol. C++ compiles all the time with bugs.
- camkego 3y agoThat used to be a joke at many places I worked at with large C/Cpp code bases. Always said tongue in cheek.
- PoignardAzur 3y agoI've experienced it a bit in C++, especially after coming back from JS. But not to the degree of Rust.