이름공간
변수
행위

C++ 키워드

cppreference.com
< cpp
 
 
C++ 언어
General topics
Flow control
Conditional execution statements
Iteration statements
Jump statements
Functions
function declaration
lambda function declaration
function template
inline specifier
exception specifications (deprecated)
noexcept specifier (C++11)
Exceptions
Namespaces
Types
decltype specifier (C++11)
Specifiers
cv specifiers
storage duration specifiers
constexpr specifier (C++11)
auto specifier (C++11)
alignas specifier (C++11)
Initialization
Literals
Expressions
alternative representations
Utilities
Types
typedef declaration
type alias declaration (C++11)
attributes (C++11)
Casts
implicit conversions
const_cast conversion
static_cast conversion
dynamic_cast conversion
reinterpret_cast conversion
C-style and functional cast
Memory allocation
Classes
Class-specific function properties
Special member functions
Templates
class template
function template
template specialization
parameter packs (C++11)
Miscellaneous
Inline assembly
 
 

다음 목록은 C++에 예약된 키워드입니다. 이들은 언어에 의해 사용되므로, 재정의나 오버로드 할 수 없습니다.

A – C D – P R – Z

alignas (C++11)
alignof (C++11)
and
and_eq
asm
atomic_cancel (TM TS)
atomic_commit (TM TS)
atomic_noexcept (TM TS)
auto (1)
bitand
bitor
bool
break
case
catch
char
char8_t (C++20)
char16_t (C++11)
char32_t (C++11)
class (1)
compl
concept (C++20)
const
consteval (C++20)
constexpr (C++11)
constinit (C++20)
const_cast
continue
co_await (C++20)
co_return (C++20)
co_yield (C++20)

decltype (C++11)
default (1)
delete (1)
do
double
dynamic_cast
else
enum
explicit
export (1) (3)
extern (1)
false
float
for
friend
goto
if
inline (1)
int
long
mutable (1)
namespace
new
noexcept (C++11)
not
not_eq
nullptr (C++11)
operator
or
or_eq
private
protected
public

reflexpr (reflection TS)
register (2)
reinterpret_cast
requires (C++20)
return
short
signed
sizeof (1)
static
static_assert (C++11)
static_cast
struct (1)
switch
synchronized (TM TS)
template
this (4)
thread_local (C++11)
throw
true
try
typedef
typeid
typename
union
unsigned
using (1)
virtual
void
volatile
wchar_t
while
xor
xor_eq

  • (1) — meaning changed or new meaning added in C++11.
  • (2) — meaning changed in C++17.
  • (3) — meaning changed in C++20.
  • (4) — new meaning added in C++23.

추가로 and, bitor, or, xor, compl, bitand, and_eq, or_eq, xor_eq, not, not_eq는 (이중문자 <%, %>, <:, :>, %:, %:%:와 함께) 표준 토큰을 위한 대체표현을 제공합니다.

키워드에 더해, 특별한 의미를 가지는 식별자가 있습니다. 이것은 객체나 함수의 이름으로서 사용되지만 특정 문맥에서 특별한 의미를 가집니다.

override (C++11)

final (C++11)
transaction_safe (TM TS)
transaction_safe_dynamic (TM TS)
import (C++20)
module (C++20)


또한 언더스코어 두 개가 포함되어 있거나 언더스코어 한 개로 시작하여 대문자 알파벳으로 이어지는 이름은 언제나 구현을 위한 예약되어 있고 식별자로 사용해서는 안됩니다. 모든 언더스코어로 시작하는 식별자는 전역 네임스페이스 안의 이름으로 사용하도록 예약되어 있습니다.