Discussion

Ask HN: Big C++ projects that uses Exceptions and RTTI?

In my career the places I have been that uses C++ (with success) have all been using -fno-exceptions and -fno-rtti. All major open-source C++ projects seem to do the same. Chromium, LLVM, Electron, protobuf etc.

I guess if you want to excel at this language and build software (in C++) that people actually use you have to learn to use it without exceptions and rtti?

Some projects do use them like CMake. I think bloomberg also uses exceptions??

Maybe Meta also uses them but again if you look at another Meta C++ project like Hermes they prohibit use of both rtti and exceptions.

Do you use exceptions in your codebase? If you intend to keep coding in C++ are you not better off learning how to use the language without exceptions and rtti?

15 points kwant_kiddo 2 years ago 4 comments

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton