Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

I suggest looking at some of Google's open sourced projects.

- Abseil: https://github.com/abseil/abseil-cpp https://cs.opensource.google/abseil

- Tensorflow: https://github.com/tensorflow/tensorflow/tree/master/tensorf... https://cs.opensource.google/tensorflow

- Chrome https://chromium.googlesource.com/chromium/src.git/+/refs/he... https://source.chromium.org/chromium

There is a very high bar for C++ code quality at Google, and also a published style / best practices guide as well as a code search engine to browse the code more easily.



But be careful about picking up Googlisms.

Google's allergy to exceptions pollutes their designs. Any class with default constructor, Init, and Deinit is badly polluted.


I have worked on many C++ codebases and none of them used exceptions pervasively. It works fine and I don't miss surprise return values.


Why though? Realtime systems, games would love to disable exceptions.


I code realtime systems with submicrosecond deadlines. And exceptions.

It is necessary to know what you are doing.


Exceptions are much more needed than the current counterhype makes it appear.




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: