javascript中的关键字和保留字
点击次数:45 次 发布日期:2008-12-13 11:11:50 作者:源代码网
|
今天在给一个对象添加名为enum的方法时,在IE下发生了错误,当时有点奇怪,然后想了下估计是javascript中关键字的问题,将名称替换了下,确实就没有问题了。现在将它的关键字和保留字贴出来,便于日后查看和避免在次出现类似的问题。 1 关键字 break case catch continue default delete do else finally for function if in instanceof new return switch this throw try typeof var void while with 2 保留字 abstract boolean byte char class const debugger double enum export extends fimal float goto implements import int interface long mative package private protected public short static super synchronized throws transient volatile |
