- Atom
- Expression
- Statement #这里讲的主要是这个 看 ECMA-262 里面就能够很清晰的看到这些JS 的statement
- Structure
- Program/Module
Grammar
简单语句
- Expression Statement 表达式语句
- Empty Statement 空语句
- Debugger Statement debugger语句,运行时不产生作用
- ThrowStatement
- Continue Statement(与循环相互匹配)
- Break Statement(与循环匹配)
- Return Statement
组合语句
{
...
...
}
while()
do...while
for
for...in...
for...of...
声明
- FunctionDeclaration
- GeneratorDeclaration
- AsyncFunctionDeclaration
- AsyncGeneratorDeclaration
- VariableStatemeny
- ClassDeclaration
- LexicalDeclaration
标签、循环、break、continue
- LabelledStatement
- IterationStatement
- ContinueStatement
- BreakStatement
- SwitchStatement
Runtime:
- Complection Record
- [[type]]: normal, break, continue, return, throw
- [[value]]: Types
- [[target]]: label
- Lexical Enviorment(推荐使用前三种)
- {} . [] Object.defineProperty
- Object.create Object.setPrototypeOf Object.getPrototypeOf
- new class extends
- new function prototype(用这种会被打死)