News for hackers. Stuff that matters.
Re:C++20, How Hard Could It Be by mrazomor on Sunday September 25, 2022 @03:06PM (#32974839)
"no exceptions" is one of the best parts of Google style guide, IMO. Note that, banning of exceptions introduced returning status (error codes done right). It makes it easier to follow the code and makes the code more readable (but, you need a few macros, unfortunately).
Re:C++20, How Hard Could It Be by int_19h on Sunday September 25, 2022 @07:45PM (#32977680)
In a language like C++ returning status codes means that callers can and will ignore it, even when they shouldn't.
Re:C++20, How Hard Could It Be by zetafunction on Sunday September 25, 2022 @08:52PM (#32978127)
Since C++17, using [[nodiscard]] can help with that.
Re:C++20, How Hard Could It Be by jandrewrogers on Sunday September 25, 2022 @09:20PM (#32978302)
Indeed, Google's implementation of Status/StatusOr requires explicit handling of those objects, they cannot be discarded automatically.
Re:C++20, How Hard Could It Be by ncmncm on Sunday September 25, 2022 @04:30PM (#32975815)
OK if you like 10-15% performance loss off the top.

And incompatibility with the rest of the world.