Movatterモバイル変換


[0]ホーム

URL:


cppreference.com
Namespaces
Variants
    Actions

      Basic concepts

      From cppreference.com
      <cpp‎ |language
       
       
      C++ language
      General topics
      Flow control
      Conditional execution statements
      Iteration statements (loops)
      Jump statements
      Functions
      Function declaration
      Lambda function expression
      inline specifier
      Dynamic exception specifications(until C++17*)
      noexcept specifier(C++11)
      Exceptions
      Namespaces
      Types
      Specifiers
      constexpr(C++11)
      consteval(C++20)
      constinit(C++20)
      Storage duration specifiers
      Initialization
      Expressions
      Alternative representations
      Literals
      Boolean -Integer -Floating-point
      Character -String -nullptr(C++11)
      User-defined(C++11)
      Utilities
      Attributes(C++11)
      Types
      typedef declaration
      Type alias declaration(C++11)
      Casts
      Memory allocation
      Classes
      Class-specific function properties
      Special member functions
      Templates
      Miscellaneous
       
       

      This section provides definitions for the specific terminology and the concepts used when describing the C++ programming language.

      A C++ program is a sequence of text files (typically header and source files) that containdeclarations. They undergotranslation to become an executable program, which is executed when the C++ implementation calls itsmain function.

      Certain words in a C++ program have special meaning, and these are known askeywords. Others can be used asidentifiers.Comments are ignored during translation. C++ programs also containliterals, the values of characters inside them are determined bycharacter sets and encodings. Certain characters in the program have to be represented withescape sequences.

      Theentities of a C++ program are values,objects,references,structured bindings(since C++17),result bindings(since C++26),functions,enumerators,types, class members,templates,template specializations,packs(since C++11), andnamespaces. Preprocessormacros are not C++ entities.

      Declarations may introduce entities, associate them withnames and define their properties. The declarations that define all properties required to use an entity aredefinitions. A program must contain only one definition of any non-inline function or variable that isodr-used.

      Definitions of functions usually include sequences ofstatements, some of which includeexpressions, which specify the computations to be performed by the program.

      Names encountered in a program are associated with the declarations that introduced them usingname lookup. Each name is only valid within a part of the program called itsscope. Some names havelinkage which makes them refer to the same entities when they appear in different scopes or translation units.

      Each object, reference, function, expression in C++ is associated with atype, which may befundamental, compound, oruser-defined, complete orincomplete, etc.

      Declared objects and declared references that are notnon-static data members arevariables .

      [edit]See also

      C documentation forBasic concepts
      Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/language/basic_concepts&oldid=181096"

      [8]ページ先頭

      ©2009-2025 Movatter.jp