This post is from a low-reputation account and contains an unverified outbound link. Be cautious before clicking external links.

What is Carbon? A successor of C++?

Words
201
Reading
1 min
Listen
Play
4y

Google engineers developed the Carbon programming language to address the shortcomings of C++.

Many existing languages like Golang and Rust already exist that mirror the performance of C++ without its shortcomings. Unfortunately, these languages present significant barriers to the migration of existing C++ codebases.

Carbon aims to be what TypeScript is to JavaScript, and Kotlin is to Java. It is not a replacement, but a successor language designed around interoperability with C++. It aims for large-scale adoption and migration for existing codebases and developers.

Getting Started With Carbon

You can explore Carbon right now by checking out the codebase and using Carbon explorer:

Install bazelisk using Homebrew.

$ brew install bazelisk

Install Clang/LLVM using Homebrew.

Many Clang/LLVM releases aren't built with options we rely on.

$ brew install llvm
$ export PATH="$(brew --prefix llvm)/bin:${PATH}"

Download Carbon's code.

$ git clone https://github.com/carbon-language/carbon-lang
$ cd carbon-lang

Build and run the explorer.

$ bazel run //explorer -- ./explorer/testdata/print/format_only.carbon


According to the Carbon roadmap, Google will make the experiment public with the release of a core working version (0.1) by the end of 2022. They plan to follow this with a 0.2 version in 2023 and a full 1.0 release in 2024–2025.

What is Carbon? A successor of C++? | Ecency