[Valid tive C ++ Reading Notes] 001 _ clause 01 _ regard C ++ as a Language Federation

Source: Internet
Author: User

With regard to these terms, the author has been emphasizing to us that we should not regard C ++ as the pure language we have learned, c ++ should be regarded as a federated language with multiple independent features.

1. c ++ developed from C and is compatible with all c syntax features. Therefore, the first federated in C ++ --C language, which is a process-oriented representative language.

2. From the very beginning, C ++ introduced the object-oriented feature, namely the name C with classes at the beginning, which is the second Federation of C ++ --Object-oriented language.

3. c ++ template. This part of the syntax makes C ++ support generic programming. Therefore, this can be the third federated of C ++ --TemplateProgramming Language.

4. the last is the famous STL, which is the masterpiece of C ++ generic programming. Although it is under the C ++ language framework, it still needs to follow its own rules when using it, that is, the fourth federated --STL.

When the author suggests that we should not use C ++ as a language, but as N languages, because C ++ covers a wide range, this leads to the extreme complexity of C ++ and various kinds of its rule conventions, therefore, when we use C ++ to switch to another method of C ++ in one way of work, we must be able to instantly adapt to the Conventions of different use methods.

In short, in my opinion, C ++ itself has become a mixture of all languages, covering the process-oriented, object-oriented, functional, paradigm, and meta-programming languages. At the same time, I personally summarized a sentence to describe C ++:

C ++ is a very flexible language with a bunch of syntax constraints, but it also provides a way to lift these constraints. Therefore, C ++ is a language that gives you constraints and full freedom. In short, your creativity can be used in both the constraints and the constraints.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.