MCPcopy Create free account
hub / github.com/babel/babel / parseClassSuper

Function parseClassSuper

packages/babel-parser/src/parser/statement.ts:2218–2229  ·  view source on GitHub ↗
(
    this: Parser,
    node: Undone<N.Class | N.StructDeclaration>,
  )

Source from the content-addressed store, hash-verified

2216
2217 // https://tc39.es/ecma262/#prod-ClassHeritage
2218 parseClassSuper(
2219 this: Parser,
2220 node: Undone<N.Class | N.StructDeclaration>,
2221 ): void {
2222 if (this.eat(tt._extends)) {
2223 this.state.canStartArrow = false;
2224 this.classHeritageStart = this.state.start;
2225 node.superClass = this.parseExprSubscripts();
2226 } else {
2227 node.superClass = null;
2228 }
2229 }
2230
2231 parseStructDeclaration(
2232 this: Parser,

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected