Google’s new programming language Carbon seeks to replace C.

As an experimental replacement for C, Google today launched Carbon, the newest programming language.

Google has developed a number programming languages over the years, some of which have gained significant notoriety and prominence. For instance, Golang (or just Go) was developed to facilitate the creation of servers and distributed systems and has subsequently been embraced by the general public. The Dart programming language, which was first meant to serve as a JavaScript substitute, didn’t gain widespread acceptance until the release of Flutter.

Chandler Carruth, a Google employee, presented the idea for a brand-new programming language called Carbon today at the Cpp North conference in Toronto, as shared by Conor Hoekstra who attended and captured the slideshow did. To set the stage, Carruth demonstrated how several of the most widely used programming languages today have descendants that enable developers to work quickly and take advantage of contemporary language design.

Like iOS developers, Android developers are fully aware that Kotlin is the replacement for Java and that Swift is the replacement for Objective-C. Microsoft’s TypeScript has significantly improved JavaScript while still being easy to use and able to be converted back to JavaScript. Similar to how C is somewhat of a sequel to the original C programming language, C is widely used within Google.

Carruth questions if the analogy still holds true even though some have suggested that Rust, a Mozilla project that has now gained a sizable following among the general public, is a replacement for C. Rust is without a doubt a fantastic language with which to begin a new project, but because it lacks the same bi-directional compatibility as something like Java and Kotlin, it is challenging to gradually transfer.

Use Rust if it works for you right now. However, switching a C environment to Rust is challenging.

To that reason, Carbon is meant to be completely interoperable with current C code, even if it has many objectives with Rust, such as assisting programmers in creating performance-critical software. In addition, it is intended to make moving from C to Carbon as simple as possible.

Carruth discussed many of the benefits of the language on stage when asked why a C developer might want to think about integrating Carbon into their project.

introduction phrases and basic grammar Values for function input parameters are read-only. Pointers offer unauthorized access and mutation Express kinds using expressions The root namespace is the package. APIs can be imported using their package names. A method is declared via an explicit object parameter. Classes are final by default; there is only one inheritance Strong generics with definition checks Types specifically carry out interfaces The Carbon team called attention to the development process that will determine the language’s future in addition to the language’s features. The project’s code is hosted publicly on GitHub and available for pull requests, while Carbons is culture is outlined to be inclusive of both company workers and unpaid persons.

However, Google’s involvement is one feature of the Carbon programming language that is not especially clearly described. There is no mention of Carbon being a Google project, despite the fact that today’s presentation was presented by a Googler and the current project leads for it are mostly but not exclusively Googlers.

Although Carbon began its life at Google, the team knows and has shared online that for it to succeed in the future, Carbon must be an autonomous and community-driven initiative, not just driven by Google’s own uses. Carruth emphasizes once more in the same statement that Carbon is still only an experiment, despite the fact that several businesses have already expressed early interest in it.

You can download the source code and play with Carbon on your own smartphone if you’re interested in getting started. Or, you can use integration with the free Compiler Explorer web app to get a feel for the Carbon programming language right in your browser.

This article formerly stated falsely that all of Carbons leads work for Google. We sincerely regret the error.
FTC: We employ automatically earning affiliate connections. More.
Check out 9to5Google on YouTube for more news:


Related Posts