search
HomeBackend DevelopmentC++History of C and C . Part one: emergence and standardization of C language. C with Classes becomes C

C and C are iconic languages in which a huge amount of code is written. What path have they traveled to become ones? This article covers the emergence of C and the beginning of its official standardization. Also, you'll learn about C with Classes and its eventual transformation into C .

History of C and C  . Part one: emergence and standardization of C language. C with Classes becomes C

1969 — 1973. C is born into the world

1969. Apollo 11 visits the Moon. AT&T Bell Labs develops a language we all know today as C. At this time, a Unix operating system is at the early development stage.

In fact, the C language took over the main features from the B language. As well as the origin of its name. As for Unix, it was initially implemented in assembly language and didn't even have a compiler for high-level languages. This project's development attributes to one of the reasons for the C language creation.

In 1971, the compiler and some utilities in C were included in the second version of Unix. And in 1973, the Unix kernel was largely written in C.

1978. The book becomes the first specification

Dennis Ritchie and Brian Kernighan published the first edition of the "The C Programming Language" on February 22, 1978. This book was the first widely available material on the C language.

History of C and C  . Part one: emergence and standardization of C language. C with Classes becomes C

Figure N1 - Cover of the first edition of the book "C Programming Language"

It has become a standard for C development from the time of its publication until the first official language certification. The "standard" was called K&R—after the first letters of the authors' last names.

This book introduced the "Hello World" program as an example of a minimal working program. After 1978, almost every book on programming languages couldn't do without this code example. Today, displaying "Hello World" as your first program is a well-established tradition.

#include <stdio.h>

main()
{
    printf("Hello, World\n");
}
</stdio.h>

K&R presented several language features. For example, structures—a set of several variables grouped under a single name for ease of reference, as well as long int and unsigned int data types.

Addition/subtraction operators with assignment also changed in K&R C. Previously, to increase a value by one, you had to write a = 1, but such operators were confusing the C compiler. Besides, the difference between a = 1 (increase by one) and a = 1 (assignment) looked rather fragile from the human point of view. It was in K&R C that these operators turned into familiar ones—a = 1.

The code examples in the book were designed in a uniform style, which was also named after the first letters of the creators' last names. The K&R style is notable for the use of eight whitespaces as the main indentation (although four whitespaces are more commonly used). It is also called the "kernel style", as the Unix kernel is written in this style.

#include <stdio.h>

main()
{
    printf("Hello, World\n");
}
</stdio.h>

1979. C with classes

In May 1979, Bell Labs employee Bjarne Stroustrup began developing a system that was to be the first Unix cluster. In other words, he started to create a distributed computing system connected to a common network of several computers.

The problem was the lack of a suitable toolkit for this. Among the existing programming languages, there were two options that could help solve this problem, but both had nuances. The BCPL language was fast but unsuitable for large projects as it was quite close to low-level languages. The object-oriented programming language Simula, on the other hand, was suitable for the task but was quite slow. So Stroustrup set out to implement his own C-based language.

As early as October 1979, the CPRE preprocessor, adding classes, to C was ready. The language was called C with Classes. One could write the program code and pass it to the preprocessor. However, it was still considered to be an extension to C.

In addition to classes, the first version of C with Classes included:

  • derived classes, but with no virtual functions yet;
  • access control;
  • constructors and destructors;
  • friend classes;
  • control and casting of function argument types.

1983. ANSI C

The language was growing in popularity:

  • C began to displace Basic as the leading language for programming microcomputers;
  • New compilers appeared. What's more, they were written by people who weren't directly involved in the language development.

But even with that popularity, C only had the unspoken standard of K&R. Developers of the compilers were introducing a lot of non-standard changes to the language. This is when the problem of code portability began to heat up. The first C standard began to emerge given this range of issues.

In 1983, the American National Standards Institute (ANSI) formed a committee to draft the specification. The standardization process ended only in 1989, when the first standard for the language was ratified as "ANSI X3.159-1989: Programming Language C". In the same year, the second edition of the book "The C Programming Language" was published, describing the language as it appears in the standard. In a year's time, this standard was approved by the International Organization for Standardization (ISO) with minor changes.

History of C and C  . Part one: emergence and standardization of C language. C with Classes becomes C

Figure N2 - Cover of the second edition of the book "C Programming Language"

In addition to a setback of changes to the language since K&R, the standard included entirely new features, such as function prototypes and a more sophisticated preprocessor. The standard also included a description of the standard library composition. In addition, some means that hadn't been defined earlier were given more precise definitions.

1983. C with Classes C

In 1982, Bjarne Stroustrup began working on changes that would bring C with Classes out of the state, which its creator called a "medium success". Starting from that moment, it took a year to develop a compiler. Cfront came out in 1983.

Its key feature was that it converted C with classes into C code. After that, the converted code was passed to the C compiler. This feature enabled more people to use the compiler, as well as to use it on an existing Unix infrastructure.

As the language evolved, its name changed several times. It was first called C84 because the community called it just C. However, the name was also misleading, as it was more like a new C standard than a subset of the language. And it didn't actually help with the problem of the previous name. Eventually the language became known as C , that is, C and the increment operator.

When moving from C with classes to C , other new features appeared in the language:

  • virtual functions;
  • function name and operator overloading;
  • references;
  • constants;
  • improved type checking;
  • user-controlled free-store memory control.

The commenting style, which is still used today, took root at this very stage of language development. The style is used in other languages as well.

This is how C lived before the official certification. Stroustrup was rather promptly responding to the programmer community's requests. His was publishing works representing the standard descriptions of the language. So, the language was maintained mainly due to the efforts of its creator.

1985. "The C programming language."

In February 1985, the first distributable version of C was released. In October of the same year, the language creator Bjarne Stroustrup released the first edition of the book "The C Programming Language."

History of C and C  . Part one: emergence and standardization of C language. C with Classes becomes C

Figure N3 - Cover of the first edition of the book "The C Programming Language"

It became the first tacit standard for the C language just like Kernighan and Ritchey's book "The C Programming Language." It was until the first official standard.

In the book, Stroustrup covered the language features as well as design issues from the C perspective, spicing up each point with plenty of code examples.

Since then, the book has been reprinted three more times, each time with language updates. At the time of writing, the most recent 4th edition includes the C 11 standard.

1989. C 2.0

In July 1989, the Cfront 2.0 compiler was released. It was substantially revised compared to the previous version and also brought novelties to the C language.

At this time, templates have already become the talk of the town. No one doubted that they would be implemented, as it was a realistic objective. As for another potential outstanding feature—multiple inheritance—was a real challenge for the creators from the programming community. Many have said that implementing multiple inheritance in C is impossible. In Simula, for example, a similar suggestion was rejected because of the inevitable complexity of the garbage collector. However, multiple inheritance was badly needed, as it would greatly simplify the development of libraries whose code was quite cumbersome without it.

As a result, multiple inheritance was added in Cfront 2.0 after all. This addition to the language has sparked controversy. For example, some have argued that the Smalltalk language, the epitome of object-oriented programming, doesn't have multiple inheritance. That's why C certainly shouldn't adopt it. The language creator assumed that such a reaction is due to taking multiple inheritance too seriously.

The above C version also introduced:

  • pointers to members, which allowed creating pointers to non-static fields and functions;
  • static and const member functions;
  • access modifier protected;
  • type-safe linkage;
  • abstract classes;
  • new and delete specific to classes;

1990. Borland C

In 1990, Borland released the Borland C integrated development environment for developing C and C programs (what a twist, hah?). It was originally intended for development under DOS, but later Windows support was introduced as well.

History of C and C  . Part one: emergence and standardization of C language. C with Classes becomes C

Figure N4 - Screenshot from Borland C

Historically, Borland C was a descendant of Turbo C but incorporated the hallmarks of C —support of object-oriented programming.

Each version of the environment had its own compiler supporting its own standards. Over time, Borland C got a lot of specialized libraries for fast application development.

The last Borland C IDE version was released in 1997, after which it was replaced by the Borland C Builder series. The finale of Borland C came in 2000 with the release of Borland C 5.5 coming with a compiler.

Borland C was a nice cozy editor for DOS. There was even some kind of syntax coloring.

Yuri Minaev, the architect of C and C core of PVS-Studio analyzer

Four years after Borland, Microsoft released its Visual C integrated development environment.

1990. Templates and exception handling mechanism in C

In 1986, Bjarne Stroustrup wrote an article "What is Object-Oriented Programming?" in which he voiced three flaws of C :

  • a lack of support for parameterized types;
  • a lack of standard exception handling mechanisms;
  • a lack of multiple inheritance.

Multiple inheritance was introduced in 1989 with C 2.0, and the rest of the flaws were fixed in 1990 with new language features. They were described by Stroustrup in the book "Annotated C Reference Manual".

Templates and exception handling appeared soon, one after another. Templates were approved in Seattle in July, and the exception handling mechanism was approved in Palo Alto in November. Their close releases are due to the fact that both of these innovations address similar problems. According to the language creator himself, templates allow you to reduce the number of errors during program execution by extending the capabilities of the static type system. While exceptions allow you to handle the remaining errors.

Parameterized types were considered back in the first edition of C . Yet they had to be postponed due to a lack of time for sufficient study of design and implementation issues. Exceptions were also postponed for the same reason. And it wasn't for nothing. Their design lasted from 1984 to 1989.

The "Annotated C Reference Manual" also introduced namespaces and the ability to identify types at runtime.

Generic programming started to gain momentum at that point. C with templates was not a pioneer. When creating templates, the creators were drawing ideas from ML, CLU, and Ada programming languages.

However, it is safe to say that C was promoting this paradigm. Templates made it possible to write code without macros in many cases, reducing the chances of shooting oneself in the foot. Here comes a fly in the ointment —the fully operating functionality that simplifies work with generic programming appeared only by C 20. But even that didn't stop programmers when they learned that templates could enable computations at the compilation stage...

On the other hand, exceptions in C are not that clear-cut. Unfortunately, they did not solve all the error handling problems compared to earlier approaches. The control flow becomes non-trivial when using exceptions. There are tons of ways to shoot oneself in the foot with them, such as privately inheriting exceptions, catching exceptions by value, or arranging catch blocks in the wrong order, etc. As a result, some coding standards prohibit their use, such as Google C Code Style.

Philipp Khandelyants, Team Lead of the C and C development team at PVS-Studio

"Annotated C Reference Manual" has become some kind a precursor to the official C standardization. It described all the innovations that would soon become the standard for the language.

In the next series...

In this article, we covered events in the history of C and C from 1969 to 1990. In the next article, we will delve into the history of C from 1991 to the present day:

  • Bjarne Stroustrup's book on how C was created;
  • C 98 is the first official standard;
  • C99—C keeps moving;
  • Technical Report 1—new C features on paper;
  • Viva64 release, later—PVS-Studio;
  • C records what has been achieved (C99, C11), and C gains momentum (C 11, C 17);
  • C 20 and C 23.

The above is the detailed content of History of C and C . Part one: emergence and standardization of C language. C with Classes becomes C. For more information, please follow other related articles on the PHP Chinese website!

Statement
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Debunking the Myths: Is C   Really a Dead Language?Debunking the Myths: Is C Really a Dead Language?May 05, 2025 am 12:11 AM

C is not dead, but has flourished in many key areas: 1) game development, 2) system programming, 3) high-performance computing, 4) browsers and network applications, C is still the mainstream choice, showing its strong vitality and application scenarios.

C# vs. C  : A Comparative Analysis of Programming LanguagesC# vs. C : A Comparative Analysis of Programming LanguagesMay 04, 2025 am 12:03 AM

The main differences between C# and C are syntax, memory management and performance: 1) C# syntax is modern, supports lambda and LINQ, and C retains C features and supports templates. 2) C# automatically manages memory, C needs to be managed manually. 3) C performance is better than C#, but C# performance is also being optimized.

Building XML Applications with C  : Practical ExamplesBuilding XML Applications with C : Practical ExamplesMay 03, 2025 am 12:16 AM

You can use the TinyXML, Pugixml, or libxml2 libraries to process XML data in C. 1) Parse XML files: Use DOM or SAX methods, DOM is suitable for small files, and SAX is suitable for large files. 2) Generate XML file: convert the data structure into XML format and write to the file. Through these steps, XML data can be effectively managed and manipulated.

XML in C  : Handling Complex Data StructuresXML in C : Handling Complex Data StructuresMay 02, 2025 am 12:04 AM

Working with XML data structures in C can use the TinyXML or pugixml library. 1) Use the pugixml library to parse and generate XML files. 2) Handle complex nested XML elements, such as book information. 3) Optimize XML processing code, and it is recommended to use efficient libraries and streaming parsing. Through these steps, XML data can be processed efficiently.

C   and Performance: Where It Still DominatesC and Performance: Where It Still DominatesMay 01, 2025 am 12:14 AM

C still dominates performance optimization because its low-level memory management and efficient execution capabilities make it indispensable in game development, financial transaction systems and embedded systems. Specifically, it is manifested as: 1) In game development, C's low-level memory management and efficient execution capabilities make it the preferred language for game engine development; 2) In financial transaction systems, C's performance advantages ensure extremely low latency and high throughput; 3) In embedded systems, C's low-level memory management and efficient execution capabilities make it very popular in resource-constrained environments.

C   XML Frameworks: Choosing the Right One for YouC XML Frameworks: Choosing the Right One for YouApr 30, 2025 am 12:01 AM

The choice of C XML framework should be based on project requirements. 1) TinyXML is suitable for resource-constrained environments, 2) pugixml is suitable for high-performance requirements, 3) Xerces-C supports complex XMLSchema verification, and performance, ease of use and licenses must be considered when choosing.

C# vs. C  : Choosing the Right Language for Your ProjectC# vs. C : Choosing the Right Language for Your ProjectApr 29, 2025 am 12:51 AM

C# is suitable for projects that require development efficiency and type safety, while C is suitable for projects that require high performance and hardware control. 1) C# provides garbage collection and LINQ, suitable for enterprise applications and Windows development. 2)C is known for its high performance and underlying control, and is widely used in gaming and system programming.

How to optimize codeHow to optimize codeApr 28, 2025 pm 10:27 PM

C code optimization can be achieved through the following strategies: 1. Manually manage memory for optimization use; 2. Write code that complies with compiler optimization rules; 3. Select appropriate algorithms and data structures; 4. Use inline functions to reduce call overhead; 5. Apply template metaprogramming to optimize at compile time; 6. Avoid unnecessary copying, use moving semantics and reference parameters; 7. Use const correctly to help compiler optimization; 8. Select appropriate data structures, such as std::vector.

See all articles

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

Video Face Swap

Video Face Swap

Swap faces in any video effortlessly with our completely free AI face swap tool!

Hot Tools

EditPlus Chinese cracked version

EditPlus Chinese cracked version

Small size, syntax highlighting, does not support code prompt function

Safe Exam Browser

Safe Exam Browser

Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

SublimeText3 Linux new version

SublimeText3 Linux new version

SublimeText3 Linux latest version

VSCode Windows 64-bit Download

VSCode Windows 64-bit Download

A free and powerful IDE editor launched by Microsoft