關(guān)鍵字
關(guān)鍵字不能作為標(biāo)識(shí)符(變量名),有特殊功能。
| break | case | catch | class |
|---|---|---|---|
| const | continue | debugger | default |
| delete | do | else | extends |
| finally | for | function | if |
| import | in | instanceof | return |
| super | switch | this | throw |
| typeof | var | void | while |
| with | yield |
保留字
保留字是留給以后用的關(guān)鍵字。
| implements | interface | let | package |
|---|---|---|---|
| private | protected | public | static |