What does “core language” mean?

后端 未结 3 617
故里飘歌
故里飘歌 2021-01-12 03:55

In the table on this page from the GCC documentation, one of the items (about halfway down the table) is listed as \"core language\" only. What does that mean? What parts of

相关标签:
3条回答
  • 2021-01-12 03:55

    The Standard library is part of the language. To express the subset of the language that concerns only with the rules of the syntax, semantic rules, and such but not with the library, people use the term core language. For example there is a working group called "core working group" (CWG) and "library working group" (LWG) in the C++ committee.

    0 讨论(0)
  • 2021-01-12 03:58

    Johannes's answer explains what "core language" means in general. In the specific context you ask about it means that the core language parts of n3050 are implemented in GCC 4.7, but not necessarily the library parts (those changes from the paper that apply to Clauses 17-30)

    In fact some of the library changes are also implemented in GCC 4.7, but the library status is documented elsewhere

    0 讨论(0)
  • 2021-01-12 04:21

    People often mean everything of C++ except the standard library, which is also part of the language specification.

    As an more authoritative example Stephan T. Lavavej (STL) is a key C++ developer at Microsoft. In his lecture series about the Core Language he defines it to be anything you have access to without including any header.

    He does not consider himself a Core Language developer. For example he worked on shared_ptr which is a fundamental part of C++11, arguably more fundamental than the strings and streams the comments mention.

    The C++ standard does not mention Core Language, but the standard library is

    17 Library introduction
    18 Language support library
    19 Diagnostics library
    20 General utilities library
    21 Strings library
    22 Localization library
    23 Containers library
    24 Iterators library
    25 Algorithms library
    26 Numerics library
    27 Input/output library
    28 Regular expressions library
    29 Atomic operations library
    30 Thread support library
    

    I would argue chapter 1-16 is (almost?) only concerned with the core language, but there may be more.

    0 讨论(0)
提交回复
热议问题