What is C++ written in?

C++ compilers including GCC and Clang/LLVM are implemented in C++. The original Cfront compiler — which translated C++ to C — was written in C. GCC became capable of compiling C++ and is itself written in C++. Clang, the modern alternative, is written in C++ and built on the LLVM infrastructure.

Details

The two dominant C++ compilers are GCC and Clang. Both are written in C++, making them self-hosting for the C++ language.

Cfront, the original C++ compiler developed at Bell Labs in the 1980s, was written in C and translated C++ code into C for compilation. GCC later gained C++ support and is now written in C++ itself.

Clang is built on the LLVM compiler infrastructure. Both Clang and the LLVM core libraries are implemented in C++.

Explore in the Graph

See implementation and influence relationships interactively.

Open Interactive Graph →

Related Pages