Jscript 保留字

Jscript 有一些保留字不能在标识符中使用。保留字对 Jscript 语言有特殊的含义,它们是语言语法的一部分。使用保留字在加载脚本的时候将产生编译错误。

Jscript 还有一些留作将来使用的保留字。这些字不是现在的 Jscript 语言的一部分,然而它们是为将来的使用保留的。

保留词

break delete function return typeof
case do if switch var
catch else in this void
continue false instanceof throw while
debugger finally new true with
default for null try  

为将来保留的词

abstract double goto native static
boolean enum implements package super
byte export import private synchronized
char extends int protected throws
class final interface public transient
const float long short volatile

当选择标识符时避免使用已经在内部 Jscript 对象或函数中使用的词,如 StringparseInt

脚本宝典