zoukankan      html  css  js  c++  java
  • JavaScript笔记3--标识符和保留字

    1.标识符
    javaScript标识符必须以字母,下划线(_)或美元符($)开始.后续的字符可以是字母/数字/下划线/美元符.也可以使用非英语语言或数学符号来书写标识符;

    2.保留字
    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

    3.ECMAScript5保留了以下关键字:
    class/const/enum/export/extends/import/super

    4.严格模式下的关键字:
    implements/let/private/public/yield/interface/package/protected/static/arguments/eval

    5.ECMAScripts3保留了以下关键字:
    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

    6.预定义的全局变量和函数名,应避免使用作为自己的标识符:
    arguments/encodeURI/Infinity/Number/RegExp/Array/encodeURIComponent/isFinite/Object/String/Boolean/Error/isNaN/parseFloat/SyntaxError/Date/eval/JSON/parseInt/TypeError/decodeURI/EvalError/Math/RangeError/undefined/decodeURIComponent/Function/NaN/ReferenceError/URIError

  • 相关阅读:
    浅析 KMP
    【GOJ 3049】玩具
    较详细的gdb入门教程
    【GOJ 2963】记者
    【GOJ 2961】数数
    GF OIer's Talk 维护笔记
    Linux 中 UFW 的使用
    开源是什么?能吃吗?
    个人介绍
    NOIP2020 爆零记
  • 原文地址:https://www.cnblogs.com/huguangqin/p/7208868.html
Copyright © 2011-2022 走看看