关键字是保留字。我们不能将其用作变量名称,常量名称等。下面给出了C语言中可用的C++语言中的32
个关键字列表。
auto | break | case | char | const | continue | default | do |
---|---|---|---|---|---|---|---|
double | else | enum | extern | float | for | goto | if |
int | long | register | return | short | signed | sizeof | static |
struct | switch | typedef | union | unsigned | void | volatile | while |
下面给出了在C语言中不可用的30
个C++语言关键字的列表。
asm | dynamic_cast | namespace | reinterpret_cast | bool |
---|---|---|---|---|
explicit | new | static_cast | false | catch |
operator | template | friend | private | class |
this | inline | public | throw | const_cast |
delete | mutable | protected | true | try |
typeid | typename | using | virtual | wchar_t |