9.4.3 Keywords
A keyword is an identifier-like sequence of characters that is reserved, and
cannot be used as an identifier except
when prefaced by the @ character.
Chapter 9 Lexical structure
57
keyword:: one of
abstract as base bool break
byte case catch char checked
class const continue decimal default
delegate do double else enum
event explicit extern false finally
fixed float for foreach goto
if implicit in int interface
internal is lock long namespace
new null object operator out
override params private protected public
readonly ref return sbyte sealed
short sizeof stackalloc static string
struct switch this throw true
try typeof uint ulong unchecked
unsafe ushort using virtual void
volatile while
In some places in the grammar, specific identifiers have special meaning,
but are not keywords. [Note: For
example, within a property declaration, the .get. and .set. identifiers
have special meaning (§17.6.2). An
identifier other than get or set is never permitted in these locations, so
this use does not conflict with a use of
these words as identifiers. end note]
A keyword is an identifier-like sequence of characters that is reserved, and
cannot be used as an identifier except
when prefaced by the @ character.
Chapter 9 Lexical structure
57
keyword:: one of
abstract as base bool break
byte case catch char checked
class const continue decimal default
delegate do double else enum
event explicit extern false finally
fixed float for foreach goto
if implicit in int interface
internal is lock long namespace
new null object operator out
override params private protected public
readonly ref return sbyte sealed
short sizeof stackalloc static string
struct switch this throw true
try typeof uint ulong unchecked
unsafe ushort using virtual void
volatile while
In some places in the grammar, specific identifiers have special meaning,
but are not keywords. [Note: For
example, within a property declaration, the .get. and .set. identifiers
have special meaning (§17.6.2). An
identifier other than get or set is never permitted in these locations, so
this use does not conflict with a use of
these words as identifiers. end note]
博客介绍了关键字的定义,即类似标识符的保留字符序列,除加@字符外不能用作标识符。还列举了众多关键字,如abstract、bool等。此外提到在语法某些地方,特定标识符有特殊意义但非关键字,如属性声明中的.get.和.set.。
1407

被折叠的 条评论
为什么被折叠?



