Changeset 79a0317 for imaps-frontend/node_modules/@babel/generator
- Timestamp:
- 01/21/25 03:08:24 (3 days ago)
- Branches:
- main
- Parents:
- 0c6b92a
- Location:
- imaps-frontend/node_modules/@babel/generator
- Files:
-
- 2 added
- 24 edited
Legend:
- Unmodified
- Added
- Removed
-
imaps-frontend/node_modules/@babel/generator/lib/generators/base.js
r0c6b92a r79a0317 25 25 var _node$directives$trai; 26 26 const newline = node.body.length ? 2 : 1; 27 this.printSequence(node.directives, { 28 trailingCommentsLineOffset: newline 29 }); 27 this.printSequence(node.directives, undefined, newline); 30 28 if (!((_node$directives$trai = node.directives[directivesLen - 1].trailingComments) != null && _node$directives$trai.length)) { 31 29 this.newline(newline); … … 42 40 var _node$directives$trai2; 43 41 const newline = node.body.length ? 2 : 1; 44 this.printSequence(node.directives, { 45 indent: true, 46 trailingCommentsLineOffset: newline 47 }); 42 this.printSequence(node.directives, true, newline); 48 43 if (!((_node$directives$trai2 = node.directives[directivesLen - 1].trailingComments) != null && _node$directives$trai2.length)) { 49 44 this.newline(newline); 50 45 } 51 46 } 52 this.printSequence(node.body, { 53 indent: true 54 }); 47 this.printSequence(node.body, true); 55 48 exit(); 56 49 this.rightBrace(node); -
imaps-frontend/node_modules/@babel/generator/lib/generators/base.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["File","node","program","print","interpreter","Program","_node$directives","noIndentInnerCommentsHere","printInnerComments","directivesLen","directives","length","_node$directives$trai","newline","body","printSequence"," trailingCommentsLineOffset","trailingComments","BlockStatement","_node$directives2","token","exit","enterDelimited","_node$directives$trai2","indent","rightBrace","Directive","value","semicolon","unescapedSingleQuoteRE","unescapedDoubleQuoteRE","DirectiveLiteral","raw","getPossibleRaw","format","minified","undefined","test","Error","InterpreterDirective","Placeholder","name","expectedNode"],"sources":["../../src/generators/base.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function File(this: Printer, node: t.File) {\n if (node.program) {\n // Print this here to ensure that Program node 'leadingComments' still\n // get printed after the hashbang.\n this.print(node.program.interpreter);\n }\n\n this.print(node.program);\n}\n\nexport function Program(this: Printer, node: t.Program) {\n // An empty Program doesn't have any inner tokens, so\n // we must explicitly print its inner comments.\n this.noIndentInnerCommentsHere();\n this.printInnerComments();\n\n const directivesLen = node.directives?.length;\n if (directivesLen) {\n const newline = node.body.length ? 2 : 1;\n this.printSequence(node.directives, {\n trailingCommentsLineOffset: newline,\n });\n if (!node.directives[directivesLen - 1].trailingComments?.length) {\n this.newline(newline);\n }\n }\n\n this.printSequence(node.body);\n}\n\nexport function BlockStatement(this: Printer, node: t.BlockStatement) {\n this.token(\"{\");\n const exit = this.enterDelimited();\n\n const directivesLen = node.directives?.length;\n if (directivesLen) {\n const newline = node.body.length ? 2 : 1;\n this.printSequence(node.directives, {\n indent: true,\n trailingCommentsLineOffset: newline,\n });\n if (!node.directives[directivesLen - 1].trailingComments?.length) {\n this.newline(newline);\n }\n }\n\n this.printSequence(node.body, { indent: true });\n\n exit();\n this.rightBrace(node);\n}\n\nexport function Directive(this: Printer, node: t.Directive) {\n this.print(node.value);\n this.semicolon();\n}\n\n// These regexes match an even number of \\ followed by a quote\nconst unescapedSingleQuoteRE = /(?:^|[^\\\\])(?:\\\\\\\\)*'/;\nconst unescapedDoubleQuoteRE = /(?:^|[^\\\\])(?:\\\\\\\\)*\"/;\n\nexport function DirectiveLiteral(this: Printer, node: t.DirectiveLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.token(raw);\n return;\n }\n\n const { value } = node;\n\n // NOTE: In directives we can't change escapings,\n // because they change the behavior.\n // e.g. \"us\\x65 strict\" (\\x65 is e) is not a \"use strict\" directive.\n\n if (!unescapedDoubleQuoteRE.test(value)) {\n this.token(`\"${value}\"`);\n } else if (!unescapedSingleQuoteRE.test(value)) {\n this.token(`'${value}'`);\n } else {\n throw new Error(\n \"Malformed AST: it is not possible to print a directive containing\" +\n \" both unescaped single and double quotes.\",\n );\n }\n}\n\nexport function InterpreterDirective(\n this: Printer,\n node: t.InterpreterDirective,\n) {\n this.token(`#!${node.value}`);\n this.newline(1, true);\n}\n\nexport function Placeholder(this: Printer, node: t.Placeholder) {\n this.token(\"%%\");\n this.print(node.name);\n this.token(\"%%\");\n\n if (node.expectedNode === \"Statement\") {\n this.semicolon();\n }\n}\n"],"mappings":";;;;;;;;;;;;AAGO,SAASA,IAAIA,CAAgBC,IAAY,EAAE;EAChD,IAAIA,IAAI,CAACC,OAAO,EAAE;IAGhB,IAAI,CAACC,KAAK,CAACF,IAAI,CAACC,OAAO,CAACE,WAAW,CAAC;EACtC;EAEA,IAAI,CAACD,KAAK,CAACF,IAAI,CAACC,OAAO,CAAC;AAC1B;AAEO,SAASG,OAAOA,CAAgBJ,IAAe,EAAE;EAAA,IAAAK,gBAAA;EAGtD,IAAI,CAACC,yBAAyB,CAAC,CAAC;EAChC,IAAI,CAACC,kBAAkB,CAAC,CAAC;EAEzB,MAAMC,aAAa,IAAAH,gBAAA,GAAGL,IAAI,CAACS,UAAU,qBAAfJ,gBAAA,CAAiBK,MAAM;EAC7C,IAAIF,aAAa,EAAE;IAAA,IAAAG,qBAAA;IACjB,MAAMC,OAAO,GAAGZ,IAAI,CAACa,IAAI,CAACH,MAAM,GAAG,CAAC,GAAG,CAAC;IACxC,IAAI,CAACI,aAAa,CAACd,IAAI,CAACS,UAAU,EAAE;MAClCM,0BAA0B,EAAEH;IAC9B,CAAC,CAAC;IACF,IAAI,GAAAD,qBAAA,GAACX,IAAI,CAACS,UAAU,CAACD,aAAa,GAAG,CAAC,CAAC,CAACQ,gBAAgB,aAAnDL,qBAAA,CAAqDD,MAAM,GAAE;MAChE,IAAI,CAACE,OAAO,CAACA,OAAO,CAAC;IACvB;EACF;EAEA,IAAI,CAACE,aAAa,CAACd,IAAI,CAACa,IAAI,CAAC;AAC/B;AAEO,SAASI,cAAcA,CAAgBjB,IAAsB,EAAE;EAAA,IAAAkB,iBAAA;EACpE,IAAI,CAAC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,MAAM;IAAEL;EAAM,CAAC,GAAG1B,IAAI;EAMtB,IAAI,CAAC6B,sBAAsB,CAACO,IAAI,CAACV,KAAK,CAAC,EAAE;IACvC,IAAI,CAACP,KAAK,CAAC,IAAIO,KAAK,GAAG,CAAC;EAC1B,CAAC,MAAM,IAAI,CAACE,sBAAsB,CAACQ,IAAI,CAACV,KAAK,CAAC,EAAE;IAC9C,IAAI,CAACP,KAAK,CAAC,IAAIO,KAAK,GAAG,CAAC;EAC1B,CAAC,MAAM;IACL,MAAM,IAAIW,KAAK,CACb,mEAAmE,GACjE,2CACJ,CAAC;EACH;AACF;AAEO,SAASC,oBAAoBA,CAElCtC,IAA4B,EAC5B;EACA,IAAI,CAACmB,KAAK,CAAC,KAAKnB,IAAI,CAAC0B,KAAK,EAAE,CAAC;EAC7B,IAAI,CAACd,OAAO,CAAC,CAAC,EAAE,IAAI,CAAC;AACvB;AAEO,SAAS2B,WAAWA,CAAgBvC,IAAmB,EAAE;EAC9D,IAAI,CAACmB,KAAK,CAAC,IAAI,CAAC;EAChB,IAAI,CAACjB,KAAK,CAACF,IAAI,CAACwC,IAAI,CAAC;EACrB,IAAI,CAACrB,KAAK,CAAC,IAAI,CAAC;EAEhB,IAAInB,IAAI,CAACyC,YAAY,KAAK,WAAW,EAAE;IACrC,IAAI,CAACd,SAAS,CAAC,CAAC;EAClB;AACF","ignoreList":[]}1 {"version":3,"names":["File","node","program","print","interpreter","Program","_node$directives","noIndentInnerCommentsHere","printInnerComments","directivesLen","directives","length","_node$directives$trai","newline","body","printSequence","undefined","trailingComments","BlockStatement","_node$directives2","token","exit","enterDelimited","_node$directives$trai2","rightBrace","Directive","value","semicolon","unescapedSingleQuoteRE","unescapedDoubleQuoteRE","DirectiveLiteral","raw","getPossibleRaw","format","minified","test","Error","InterpreterDirective","Placeholder","name","expectedNode"],"sources":["../../src/generators/base.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function File(this: Printer, node: t.File) {\n if (node.program) {\n // Print this here to ensure that Program node 'leadingComments' still\n // get printed after the hashbang.\n this.print(node.program.interpreter);\n }\n\n this.print(node.program);\n}\n\nexport function Program(this: Printer, node: t.Program) {\n // An empty Program doesn't have any inner tokens, so\n // we must explicitly print its inner comments.\n this.noIndentInnerCommentsHere();\n this.printInnerComments();\n\n const directivesLen = node.directives?.length;\n if (directivesLen) {\n const newline = node.body.length ? 2 : 1;\n this.printSequence(node.directives, undefined, newline);\n if (!node.directives[directivesLen - 1].trailingComments?.length) {\n this.newline(newline);\n }\n }\n\n this.printSequence(node.body);\n}\n\nexport function BlockStatement(this: Printer, node: t.BlockStatement) {\n this.token(\"{\");\n const exit = this.enterDelimited();\n\n const directivesLen = node.directives?.length;\n if (directivesLen) {\n const newline = node.body.length ? 2 : 1;\n this.printSequence(node.directives, true, newline);\n if (!node.directives[directivesLen - 1].trailingComments?.length) {\n this.newline(newline);\n }\n }\n\n this.printSequence(node.body, true);\n\n exit();\n this.rightBrace(node);\n}\n\nexport function Directive(this: Printer, node: t.Directive) {\n this.print(node.value);\n this.semicolon();\n}\n\n// These regexes match an even number of \\ followed by a quote\nconst unescapedSingleQuoteRE = /(?:^|[^\\\\])(?:\\\\\\\\)*'/;\nconst unescapedDoubleQuoteRE = /(?:^|[^\\\\])(?:\\\\\\\\)*\"/;\n\nexport function DirectiveLiteral(this: Printer, node: t.DirectiveLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.token(raw);\n return;\n }\n\n const { value } = node;\n\n // NOTE: In directives we can't change escapings,\n // because they change the behavior.\n // e.g. \"us\\x65 strict\" (\\x65 is e) is not a \"use strict\" directive.\n\n if (!unescapedDoubleQuoteRE.test(value)) {\n this.token(`\"${value}\"`);\n } else if (!unescapedSingleQuoteRE.test(value)) {\n this.token(`'${value}'`);\n } else {\n throw new Error(\n \"Malformed AST: it is not possible to print a directive containing\" +\n \" both unescaped single and double quotes.\",\n );\n }\n}\n\nexport function InterpreterDirective(\n this: Printer,\n node: t.InterpreterDirective,\n) {\n this.token(`#!${node.value}`);\n this.newline(1, true);\n}\n\nexport function Placeholder(this: Printer, node: t.Placeholder) {\n this.token(\"%%\");\n this.print(node.name);\n this.token(\"%%\");\n\n if (node.expectedNode === \"Statement\") {\n this.semicolon();\n }\n}\n"],"mappings":";;;;;;;;;;;;AAGO,SAASA,IAAIA,CAAgBC,IAAY,EAAE;EAChD,IAAIA,IAAI,CAACC,OAAO,EAAE;IAGhB,IAAI,CAACC,KAAK,CAACF,IAAI,CAACC,OAAO,CAACE,WAAW,CAAC;EACtC;EAEA,IAAI,CAACD,KAAK,CAACF,IAAI,CAACC,OAAO,CAAC;AAC1B;AAEO,SAASG,OAAOA,CAAgBJ,IAAe,EAAE;EAAA,IAAAK,gBAAA;EAGtD,IAAI,CAACC,yBAAyB,CAAC,CAAC;EAChC,IAAI,CAACC,kBAAkB,CAAC,CAAC;EAEzB,MAAMC,aAAa,IAAAH,gBAAA,GAAGL,IAAI,CAACS,UAAU,qBAAfJ,gBAAA,CAAiBK,MAAM;EAC7C,IAAIF,aAAa,EAAE;IAAA,IAAAG,qBAAA;IACjB,MAAMC,OAAO,GAAGZ,IAAI,CAACa,IAAI,CAACH,MAAM,GAAG,CAAC,GAAG,CAAC;IACxC,IAAI,CAACI,aAAa,CAACd,IAAI,CAACS,UAAU,EAAEM,SAAS,EAAEH,OAAO,CAAC;IACvD,IAAI,GAAAD,qBAAA,GAACX,IAAI,CAACS,UAAU,CAACD,aAAa,GAAG,CAAC,CAAC,CAACQ,gBAAgB,aAAnDL,qBAAA,CAAqDD,MAAM,GAAE;MAChE,IAAI,CAACE,OAAO,CAACA,OAAO,CAAC;IACvB;EACF;EAEA,IAAI,CAACE,aAAa,CAACd,IAAI,CAACa,IAAI,CAAC;AAC/B;AAEO,SAASI,cAAcA,CAAgBjB,IAAsB,EAAE;EAAA,IAAAkB,iBAAA;EACpE,IAAI,CAACC,SAAK,IAAI,CAAC;EACf,MAAMC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AC,EAAE;IACvC,IAAI,CAACN,KAAK,CAAC,IAAIM,KAAK,GAAG,CAAC;EAC1B,CAAC,MAAM,IAAI,CAACE,sBAAsB,CAACO,IAAI,CAACT,KAAK,CAAC,EAAE;IAC9C,IAAI,CAACN,KAAK,CAAC,IAAIM,KAAK,GAAG,CAAC;EAC1B,CAAC,MAAM;IACL,MAAM,IAAIU,KAAK,CACb,mEAAmE,GACjE,2CACJ,CAAC;EACH;AACF;AAEO,SAASC,oBAAoBA,CAElCpC,IAA4B,EAC5B;EACA,IAAI,CAACmB,KAAK,CAAC,KAAKnB,IAAI,CAACyB,KAAK,EAAE,CAAC;EAC7B,IAAI,CAACb,OAAO,CAAC,CAAC,EAAE,IAAI,CAAC;AACvB;AAEO,SAASyB,WAAWA,CAAgBrC,IAAmB,EAAE;EAC9D,IAAI,CAACmB,KAAK,CAAC,IAAI,CAAC;EAChB,IAAI,CAACjB,KAAK,CAACF,IAAI,CAACsC,IAAI,CAAC;EACrB,IAAI,CAACnB,KAAK,CAAC,IAAI,CAAC;EAEhB,IAAInB,IAAI,CAACuC,YAAY,KAAK,WAAW,EAAE;IACrC,IAAI,CAACb,SAAS,CAAC,CAAC;EAClB;AACF","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/classes.js
r0c6b92a r79a0317 62 62 separator == null || separator(-1); 63 63 const exit = this.enterDelimited(); 64 this.printJoin(node.body, { 65 statement: true, 66 indent: true, 67 separator, 68 printTrailingSeparator: true 69 }); 64 this.printJoin(node.body, true, true, separator, true); 70 65 exit(); 71 66 if (!this.endsWith(10)) this.newline(); … … 207 202 } else { 208 203 this.newline(); 209 this.printSequence(node.body, { 210 indent: true 211 }); 204 this.printSequence(node.body, true); 212 205 this.rightBrace(node); 213 206 } -
imaps-frontend/node_modules/@babel/generator/lib/generators/classes.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","isExportDefaultDeclaration","isExportNamedDeclaration","ClassDeclaration","node","parent","inExport","_shouldPrintDecoratorsBeforeExport","printJoin","decorators","declare","word","space","abstract","id","print","typeParameters","superClass","superTypeParameters","implements","printList","body","ClassBody","token","length","newline","separator","classBodyEmptySemicolonsPrinter","exit","enterDelimited"," statement","indent","printTrailingSeparator","endsWith","rightBrace","printer","tokenMap","start","end","indexes","getIndexes","k","occurrenceCount","nextLocIndex","advanceNextLocIndex","i","tok","matchesOriginal","_tokens","undefined","ClassProperty","static","format","preserveFormat","_node$key$loc","endLine","key","loc","line","catchUp","tsPrintClassMemberModifiers","computed","_variance","optional","definite","typeAnnotation","value","semicolon","ClassAccessorProperty","_node$key$loc2","ClassPrivateProperty","ClassMethod","_classMethodHead","ClassPrivateMethod","_node$key$loc3","_methodHead","StaticBlock","printSequence"],"sources":["../../src/generators/classes.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isExportDefaultDeclaration,\n isExportNamedDeclaration,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\n\nexport function ClassDeclaration(\n this: Printer,\n node: t.ClassDeclaration,\n parent: t.Node,\n) {\n const inExport =\n isExportDefaultDeclaration(parent) || isExportNamedDeclaration(parent);\n\n if (\n !inExport ||\n !this._shouldPrintDecoratorsBeforeExport(\n parent as t.ExportDeclaration & { declaration: t.ClassDeclaration },\n )\n ) {\n this.printJoin(node.decorators);\n }\n\n if (node.declare) {\n // TS\n this.word(\"declare\");\n this.space();\n }\n\n if (node.abstract) {\n // TS\n this.word(\"abstract\");\n this.space();\n }\n\n this.word(\"class\");\n\n if (node.id) {\n this.space();\n this.print(node.id);\n }\n\n this.print(node.typeParameters);\n\n if (node.superClass) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.superClass);\n this.print(node.superTypeParameters);\n }\n\n if (node.implements) {\n this.space();\n this.word(\"implements\");\n this.space();\n this.printList(node.implements);\n }\n\n this.space();\n this.print(node.body);\n}\n\nexport { ClassDeclaration as ClassExpression };\n\nexport function ClassBody(this: Printer, node: t.ClassBody) {\n this.token(\"{\");\n if (node.body.length === 0) {\n this.token(\"}\");\n } else {\n this.newline();\n\n const separator = classBodyEmptySemicolonsPrinter(this, node);\n separator?.(-1); // print leading semicolons in preserveFormat mode\n\n const exit = this.enterDelimited();\n this.printJoin(node.body, {\n statement: true,\n indent: true,\n separator,\n printTrailingSeparator: true,\n });\n exit();\n\n if (!this.endsWith(charCodes.lineFeed)) this.newline();\n\n this.rightBrace(node);\n }\n}\n\nfunction classBodyEmptySemicolonsPrinter(printer: Printer, node: t.ClassBody) {\n if (!printer.tokenMap || node.start == null || node.end == null) {\n return null;\n }\n\n // \"empty statements\" in class bodies are not represented in the AST.\n // Print them by checking if there are any ; tokens between the current AST\n // member and the next one.\n\n const indexes = printer.tokenMap.getIndexes(node);\n if (!indexes) return null;\n\n let k = 1; // start from 1 to skip '{'\n\n let occurrenceCount = 0;\n\n let nextLocIndex = 0;\n const advanceNextLocIndex = () => {\n while (\n nextLocIndex < node.body.length &&\n node.body[nextLocIndex].start == null\n ) {\n nextLocIndex++;\n }\n };\n advanceNextLocIndex();\n\n return (i: number) => {\n if (nextLocIndex <= i) {\n nextLocIndex = i + 1;\n advanceNextLocIndex();\n }\n\n const end =\n nextLocIndex === node.body.length\n ? node.end\n : node.body[nextLocIndex].start;\n\n let tok;\n while (\n k < indexes.length &&\n printer.tokenMap.matchesOriginal(\n (tok = printer._tokens[indexes[k]]),\n \";\",\n ) &&\n tok.start < end\n ) {\n printer.token(\";\", undefined, occurrenceCount++);\n k++;\n }\n };\n}\n\nexport function ClassProperty(this: Printer, node: t.ClassProperty) {\n this.printJoin(node.decorators);\n\n if (!node.static && !this.format.preserveFormat) {\n // catch up to property key, avoid line break\n // between member TS modifiers and the property key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n }\n\n this.tsPrintClassMemberModifiers(node);\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n this._variance(node);\n this.print(node.key);\n }\n\n // TS\n if (node.optional) {\n this.token(\"?\");\n }\n if (node.definite) {\n this.token(\"!\");\n }\n\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassAccessorProperty(\n this: Printer,\n node: t.ClassAccessorProperty,\n) {\n this.printJoin(node.decorators);\n\n // catch up to property key, avoid line break\n // between member modifiers and the property key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n\n // TS does not support class accessor property yet\n this.tsPrintClassMemberModifiers(node);\n\n this.word(\"accessor\", true);\n this.space();\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n // Todo: Flow does not support class accessor property yet.\n this._variance(node);\n this.print(node.key);\n }\n\n // TS\n if (node.optional) {\n this.token(\"?\");\n }\n if (node.definite) {\n this.token(\"!\");\n }\n\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassPrivateProperty(\n this: Printer,\n node: t.ClassPrivateProperty,\n) {\n this.printJoin(node.decorators);\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.print(node.key);\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassMethod(this: Printer, node: t.ClassMethod) {\n this._classMethodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function ClassPrivateMethod(this: Printer, node: t.ClassPrivateMethod) {\n this._classMethodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function _classMethodHead(\n this: Printer,\n node: t.ClassMethod | t.ClassPrivateMethod | t.TSDeclareMethod,\n) {\n this.printJoin(node.decorators);\n\n if (!this.format.preserveFormat) {\n // catch up to method key, avoid line break\n // between member modifiers/method heads and the method key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n }\n\n this.tsPrintClassMemberModifiers(node);\n this._methodHead(node);\n}\n\nexport function StaticBlock(this: Printer, node: t.StaticBlock) {\n this.word(\"static\");\n this.space();\n this.token(\"{\");\n if (node.body.length === 0) {\n this.token(\"}\");\n } else {\n this.newline();\n this.printSequence(node.body, { indent: true });\n this.rightBrace(node);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAGsB;EAFpBC,0BAA0B;EAC1BC;AAAwB,IAAAH,EAAA;AAQnB,SAASI,gBAAgBA,CAE9BC,IAAwB,EACxBC,MAAc,EACd;EACA,MAAMC,QAAQ,GACZL,0BAA0B,CAACI,MAAM,CAAC,IAAIH,wBAAwB,CAACG,MAAM,CAAC;EAExE,IACE,CAACC,QAAQ,IACT,CAAC,IAAI,CAACC,kCAAkC,CACtCF,MACF,CAAC,EACD;IACA,IAAI,CAACG,SAAS,CAACJ,IAAI,CAACK,UAAU,CAAC;EACjC;EAEA,IAAIL,IAAI,CAACM,OAAO,EAAE;IAEhB,IAAI,CAACC,IAAI,CAAC,SAAS,CAAC;IACpB,IAAI,CAACC,KAAK,CAAC,CAAC;EACd;EAEA,IAAIR,IAAI,CAACS,QAAQ,EAAE;IAEjB,IAAI,CAACF,IAAI,CAAC,UAAU,CAAC;IACrB,IAAI,CAACC,KAAK,CAAC,CAAC;EACd;EAEA,IAAI,CAACD,IAAI,CAAC,OAAO,CAAC;EAElB,IAAIP,IAAI,CAACU,EAAE,EAAE;IACX,IAAI,CAACF,KAAK,CAAC,CAAC;IACZ,IAAI,CAACG,KAAK,CAACX,IAAI,CAACU,EAAE,CAAC;EACrB;EAEA,IAAI,CAACC,KAAK,CAACX,IAAI,CAACY,cAAc,CAAC;EAE/B,IAAIZ,IAAI,CAACa,UAAU,EAAE;IACnB,IAAI,CAACL,KAAK,CAAC,CAAC;IACZ,IAAI,CAACD,IAAI,CAAC,SAAS,CAAC;IACpB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AA,GAAGtE,IAAI,CAACoD,GAAG,CAACC,GAAG,cAAAiB,cAAA,GAAZA,cAAA,CAAcpC,GAAG,qBAAjBoC,cAAA,CAAmBhB,IAAI;IACvC,IAAIH,OAAO,EAAE,IAAI,CAACI,OAAO,CAACJ,OAAO,CAAC;EACpC;EAEA,IAAI,CAACK,2BAA2B,CAACxD,IAAI,CAAC;EACtC,IAAI,CAACuE,WAAW,CAACvE,IAAI,CAAC;AACxB;AAEO,SAASwE,WAAWA,CAAgBxE,IAAmB,EAAE;EAC9D,IAAI,CAACO,IAAI,CAAC,QAAQ,CAAC;EACnB,IAAI,CAACC,KAAK,CAAC,CAAC;EACZ,IAAI,CAACW,SAAK,IAAI,CAAC;EACf,IAAInB,IAAI,CAACiB,IAAI,CAACG,MAAM,KAAK,CAAC,EAAE;IAC1B,IAAI,CAACD,SAAK,IAAI,CAAC;EACjB,CAAC,MAAM;IACL,IAAI,CAACE,OAAO,CAAC,CAAC;IACd,IAAI,CAACoD,aAAa,CAACzE,IAAI,CAACiB,IAAI,EAAE;MAAEU,MAAM,EAAE;IAAK,CAAC,CAAC;IAC/C,IAAI,CAACG,UAAU,CAAC9B,IAAI,CAAC;EACvB;AACF","ignoreList":[]}1 {"version":3,"names":["_t","require","isExportDefaultDeclaration","isExportNamedDeclaration","ClassDeclaration","node","parent","inExport","_shouldPrintDecoratorsBeforeExport","printJoin","decorators","declare","word","space","abstract","id","print","typeParameters","superClass","superTypeParameters","implements","printList","body","ClassBody","token","length","newline","separator","classBodyEmptySemicolonsPrinter","exit","enterDelimited","endsWith","rightBrace","printer","tokenMap","start","end","indexes","getIndexes","k","occurrenceCount","nextLocIndex","advanceNextLocIndex","i","tok","matchesOriginal","_tokens","undefined","ClassProperty","static","format","preserveFormat","_node$key$loc","endLine","key","loc","line","catchUp","tsPrintClassMemberModifiers","computed","_variance","optional","definite","typeAnnotation","value","semicolon","ClassAccessorProperty","_node$key$loc2","ClassPrivateProperty","ClassMethod","_classMethodHead","ClassPrivateMethod","_node$key$loc3","_methodHead","StaticBlock","printSequence"],"sources":["../../src/generators/classes.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isExportDefaultDeclaration,\n isExportNamedDeclaration,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\n\nexport function ClassDeclaration(\n this: Printer,\n node: t.ClassDeclaration,\n parent: t.Node,\n) {\n const inExport =\n isExportDefaultDeclaration(parent) || isExportNamedDeclaration(parent);\n\n if (\n !inExport ||\n !this._shouldPrintDecoratorsBeforeExport(\n parent as t.ExportDeclaration & { declaration: t.ClassDeclaration },\n )\n ) {\n this.printJoin(node.decorators);\n }\n\n if (node.declare) {\n // TS\n this.word(\"declare\");\n this.space();\n }\n\n if (node.abstract) {\n // TS\n this.word(\"abstract\");\n this.space();\n }\n\n this.word(\"class\");\n\n if (node.id) {\n this.space();\n this.print(node.id);\n }\n\n this.print(node.typeParameters);\n\n if (node.superClass) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.superClass);\n this.print(\n process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Renamed\n node.superTypeArguments\n : // @ts-ignore(Babel 7 vs Babel 8) Renamed\n node.superTypeParameters,\n );\n }\n\n if (node.implements) {\n this.space();\n this.word(\"implements\");\n this.space();\n this.printList(node.implements);\n }\n\n this.space();\n this.print(node.body);\n}\n\nexport { ClassDeclaration as ClassExpression };\n\nexport function ClassBody(this: Printer, node: t.ClassBody) {\n this.token(\"{\");\n if (node.body.length === 0) {\n this.token(\"}\");\n } else {\n this.newline();\n\n const separator = classBodyEmptySemicolonsPrinter(this, node);\n separator?.(-1); // print leading semicolons in preserveFormat mode\n\n const exit = this.enterDelimited();\n this.printJoin(node.body, true, true, separator, true);\n exit();\n\n if (!this.endsWith(charCodes.lineFeed)) this.newline();\n\n this.rightBrace(node);\n }\n}\n\nfunction classBodyEmptySemicolonsPrinter(printer: Printer, node: t.ClassBody) {\n if (!printer.tokenMap || node.start == null || node.end == null) {\n return null;\n }\n\n // \"empty statements\" in class bodies are not represented in the AST.\n // Print them by checking if there are any ; tokens between the current AST\n // member and the next one.\n\n const indexes = printer.tokenMap.getIndexes(node);\n if (!indexes) return null;\n\n let k = 1; // start from 1 to skip '{'\n\n let occurrenceCount = 0;\n\n let nextLocIndex = 0;\n const advanceNextLocIndex = () => {\n while (\n nextLocIndex < node.body.length &&\n node.body[nextLocIndex].start == null\n ) {\n nextLocIndex++;\n }\n };\n advanceNextLocIndex();\n\n return (i: number) => {\n if (nextLocIndex <= i) {\n nextLocIndex = i + 1;\n advanceNextLocIndex();\n }\n\n const end =\n nextLocIndex === node.body.length\n ? node.end\n : node.body[nextLocIndex].start;\n\n let tok;\n while (\n k < indexes.length &&\n printer.tokenMap.matchesOriginal(\n (tok = printer._tokens[indexes[k]]),\n \";\",\n ) &&\n tok.start < end\n ) {\n printer.token(\";\", undefined, occurrenceCount++);\n k++;\n }\n };\n}\n\nexport function ClassProperty(this: Printer, node: t.ClassProperty) {\n this.printJoin(node.decorators);\n\n if (!node.static && !this.format.preserveFormat) {\n // catch up to property key, avoid line break\n // between member TS modifiers and the property key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n }\n\n this.tsPrintClassMemberModifiers(node);\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n this._variance(node);\n this.print(node.key);\n }\n\n // TS\n if (node.optional) {\n this.token(\"?\");\n }\n if (node.definite) {\n this.token(\"!\");\n }\n\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassAccessorProperty(\n this: Printer,\n node: t.ClassAccessorProperty,\n) {\n this.printJoin(node.decorators);\n\n // catch up to property key, avoid line break\n // between member modifiers and the property key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n\n // TS does not support class accessor property yet\n this.tsPrintClassMemberModifiers(node);\n\n this.word(\"accessor\", true);\n this.space();\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n // Todo: Flow does not support class accessor property yet.\n this._variance(node);\n this.print(node.key);\n }\n\n // TS\n if (node.optional) {\n this.token(\"?\");\n }\n if (node.definite) {\n this.token(\"!\");\n }\n\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassPrivateProperty(\n this: Printer,\n node: t.ClassPrivateProperty,\n) {\n this.printJoin(node.decorators);\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.print(node.key);\n this.print(node.typeAnnotation);\n if (node.value) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.value);\n }\n this.semicolon();\n}\n\nexport function ClassMethod(this: Printer, node: t.ClassMethod) {\n this._classMethodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function ClassPrivateMethod(this: Printer, node: t.ClassPrivateMethod) {\n this._classMethodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function _classMethodHead(\n this: Printer,\n node: t.ClassMethod | t.ClassPrivateMethod | t.TSDeclareMethod,\n) {\n this.printJoin(node.decorators);\n\n if (!this.format.preserveFormat) {\n // catch up to method key, avoid line break\n // between member modifiers/method heads and the method key.\n const endLine = node.key.loc?.end?.line;\n if (endLine) this.catchUp(endLine);\n }\n\n this.tsPrintClassMemberModifiers(node);\n this._methodHead(node);\n}\n\nexport function StaticBlock(this: Printer, node: t.StaticBlock) {\n this.word(\"static\");\n this.space();\n this.token(\"{\");\n if (node.body.length === 0) {\n this.token(\"}\");\n } else {\n this.newline();\n this.printSequence(node.body, true);\n this.rightBrace(node);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAGsB;EAFpBC,0BAA0B;EAC1BC;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AAK,CAAC,CAAC;EACZ,IAAI,CAACW,SAAK,IAAI,CAAC;EACf,IAAInB,IAAI,CAACiB,IAAI,CAACG,MAAM,KAAK,CAAC,EAAE;IAC1B,IAAI,CAACD,SAAK,IAAI,CAAC;EACjB,CAAC,MAAM;IACL,IAAI,CAACE,OAAO,CAAC,CAAC;IACd,IAAI,CAACiD,aAAa,CAACtE,IAAI,CAACiB,IAAI,EAAE,IAAI,CAAC;IACnC,IAAI,CAACU,UAAU,CAAC3B,IAAI,CAAC;EACvB;AACF","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/expressions.js
r0c6b92a r79a0317 98 98 } 99 99 this.print(node.typeArguments); 100 this.print(node.typeParameters); 100 { 101 this.print(node.typeParameters); 102 } 101 103 if (node.optional) { 102 104 this.token("?."); … … 107 109 this.tokenChar(40); 108 110 const exit = this.enterDelimited(); 109 this.printList(node.arguments, { 110 printTrailingSeparator: this.shouldPrintTrailingComma(")") 111 }); 111 this.printList(node.arguments, this.shouldPrintTrailingComma(")")); 112 112 exit(); 113 113 this.rightParens(node); … … 164 164 function OptionalCallExpression(node) { 165 165 this.print(node.callee); 166 this.print(node.typeParameters); 166 { 167 this.print(node.typeParameters); 168 } 167 169 if (node.optional) { 168 170 this.token("?."); … … 178 180 this.print(node.callee); 179 181 this.print(node.typeArguments); 180 this.print(node.typeParameters); 182 { 183 this.print(node.typeParameters); 184 } 181 185 this.tokenChar(40); 182 186 const exit = this.enterDelimited(); 183 this.printList(node.arguments, { 184 printTrailingSeparator: this.shouldPrintTrailingComma(")") 185 }); 187 this.printList(node.arguments, this.shouldPrintTrailingComma(")")); 186 188 exit(); 187 189 this.rightParens(node); -
imaps-frontend/node_modules/@babel/generator/lib/generators/expressions.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_index","isCallExpression","isLiteral","isMemberExpression","isNewExpression","isPattern","UnaryExpression","node","operator","word","space","token","print","argument","DoExpression","async","body","ParenthesizedExpression","exit","enterDelimited","expression","rightParens","UpdateExpression","prefix","ConditionalExpression","test","consequent","alternate","NewExpression","parent","callee","format","minified","arguments","length","optional","typeArguments","typeParameters","tokenMap","endMatches","printList"," printTrailingSeparator","shouldPrintTrailingComma","SequenceExpression","expressions","ThisExpression","Super","_shouldPrintDecoratorsBeforeExport","decoratorsBeforeExport","start","declaration","Decorator","newline","OptionalMemberExpression","computed","property","object","TypeError","value","OptionalCallExpression","CallExpression","Import","AwaitExpression","printTerminatorless","YieldExpression","delegate","EmptyStatement","semicolon","ExpressionStatement","tokenContext","TokenContext","expressionStatement","AssignmentPattern","left","type","typeAnnotation","right","AssignmentExpression","_endsWithDiv","BindExpression","MemberExpression","MetaProperty","meta","PrivateName","id","V8IntrinsicIdentifier","name","ModuleExpression","indent","directives","dedent","rightBrace"],"sources":["../../src/generators/expressions.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isCallExpression,\n isLiteral,\n isMemberExpression,\n isNewExpression,\n isPattern,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function UnaryExpression(this: Printer, node: t.UnaryExpression) {\n const { operator } = node;\n if (\n operator === \"void\" ||\n operator === \"delete\" ||\n operator === \"typeof\" ||\n // throwExpressions\n operator === \"throw\"\n ) {\n this.word(operator);\n this.space();\n } else {\n this.token(operator);\n }\n\n this.print(node.argument);\n}\n\nexport function DoExpression(this: Printer, node: t.DoExpression) {\n if (node.async) {\n this.word(\"async\", true);\n this.space();\n }\n this.word(\"do\");\n this.space();\n this.print(node.body);\n}\n\nexport function ParenthesizedExpression(\n this: Printer,\n node: t.ParenthesizedExpression,\n) {\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.print(node.expression);\n exit();\n this.rightParens(node);\n}\n\nexport function UpdateExpression(this: Printer, node: t.UpdateExpression) {\n if (node.prefix) {\n this.token(node.operator);\n this.print(node.argument);\n } else {\n this.print(node.argument, true);\n this.token(node.operator);\n }\n}\n\nexport function ConditionalExpression(\n this: Printer,\n node: t.ConditionalExpression,\n) {\n this.print(node.test);\n this.space();\n this.token(\"?\");\n this.space();\n this.print(node.consequent);\n this.space();\n this.token(\":\");\n this.space();\n this.print(node.alternate);\n}\n\nexport function NewExpression(\n this: Printer,\n node: t.NewExpression,\n parent: t.Node,\n) {\n this.word(\"new\");\n this.space();\n this.print(node.callee);\n if (\n this.format.minified &&\n node.arguments.length === 0 &&\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n !node.optional &&\n !isCallExpression(parent, { callee: node }) &&\n !isMemberExpression(parent) &&\n !isNewExpression(parent)\n ) {\n return;\n }\n\n this.print(node.typeArguments); // Flow\n this.print(node.typeParameters); // TS\n\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n if (node.optional) {\n // TODO: This can never happen\n this.token(\"?.\");\n }\n\n if (\n node.arguments.length === 0 &&\n this.tokenMap &&\n !this.tokenMap.endMatches(node, \")\")\n ) {\n return;\n }\n\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\")\"),\n });\n exit();\n this.rightParens(node);\n}\n\nexport function SequenceExpression(this: Printer, node: t.SequenceExpression) {\n this.printList(node.expressions);\n}\n\nexport function ThisExpression(this: Printer) {\n this.word(\"this\");\n}\n\nexport function Super(this: Printer) {\n this.word(\"super\");\n}\n\nexport function _shouldPrintDecoratorsBeforeExport(\n this: Printer,\n node: t.ExportDeclaration & { declaration: t.ClassDeclaration },\n) {\n if (typeof this.format.decoratorsBeforeExport === \"boolean\") {\n return this.format.decoratorsBeforeExport;\n }\n return (\n typeof node.start === \"number\" && node.start === node.declaration.start\n );\n}\n\nexport function Decorator(this: Printer, node: t.Decorator) {\n this.token(\"@\");\n this.print(node.expression);\n this.newline();\n}\n\nexport function OptionalMemberExpression(\n this: Printer,\n node: t.OptionalMemberExpression,\n) {\n let { computed } = node;\n const { optional, property } = node;\n\n this.print(node.object);\n\n if (!computed && isMemberExpression(property)) {\n throw new TypeError(\"Got a MemberExpression for MemberExpression property\");\n }\n\n // @ts-expect-error todo(flow->ts) maybe instead of typeof check specific literal types?\n if (isLiteral(property) && typeof property.value === \"number\") {\n computed = true;\n }\n if (optional) {\n this.token(\"?.\");\n }\n\n if (computed) {\n this.token(\"[\");\n this.print(property);\n this.token(\"]\");\n } else {\n if (!optional) {\n this.token(\".\");\n }\n this.print(property);\n }\n}\n\nexport function OptionalCallExpression(\n this: Printer,\n node: t.OptionalCallExpression,\n) {\n this.print(node.callee);\n\n this.print(node.typeParameters); // TS\n\n if (node.optional) {\n this.token(\"?.\");\n }\n\n this.print(node.typeArguments); // Flow\n\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments);\n exit();\n this.rightParens(node);\n}\n\nexport function CallExpression(this: Printer, node: t.CallExpression) {\n this.print(node.callee);\n\n this.print(node.typeArguments); // Flow\n this.print(node.typeParameters); // TS\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\")\"),\n });\n exit();\n this.rightParens(node);\n}\n\nexport function Import(this: Printer) {\n this.word(\"import\");\n}\n\nexport function AwaitExpression(this: Printer, node: t.AwaitExpression) {\n this.word(\"await\");\n\n if (node.argument) {\n this.space();\n this.printTerminatorless(node.argument);\n }\n}\n\nexport function YieldExpression(this: Printer, node: t.YieldExpression) {\n this.word(\"yield\", true);\n\n if (node.delegate) {\n this.token(\"*\");\n if (node.argument) {\n this.space();\n // line terminators are allowed after yield*\n this.print(node.argument);\n }\n } else {\n if (node.argument) {\n this.space();\n this.printTerminatorless(node.argument);\n }\n }\n}\n\nexport function EmptyStatement(this: Printer) {\n this.semicolon(true /* force */);\n}\n\nexport function ExpressionStatement(\n this: Printer,\n node: t.ExpressionStatement,\n) {\n this.tokenContext |= TokenContext.expressionStatement;\n this.print(node.expression);\n this.semicolon();\n}\n\nexport function AssignmentPattern(this: Printer, node: t.AssignmentPattern) {\n this.print(node.left);\n if (node.left.type === \"Identifier\" || isPattern(node.left)) {\n if (node.left.optional) this.token(\"?\");\n this.print(node.left.typeAnnotation);\n }\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.right);\n}\n\nexport function AssignmentExpression(\n this: Printer,\n node: t.AssignmentExpression | t.BinaryExpression | t.LogicalExpression,\n) {\n this.print(node.left);\n\n this.space();\n if (node.operator === \"in\" || node.operator === \"instanceof\") {\n this.word(node.operator);\n } else {\n this.token(node.operator);\n this._endsWithDiv = node.operator === \"/\";\n }\n this.space();\n\n this.print(node.right);\n}\n\nexport function BindExpression(this: Printer, node: t.BindExpression) {\n this.print(node.object);\n this.token(\"::\");\n this.print(node.callee);\n}\n\nexport {\n AssignmentExpression as BinaryExpression,\n AssignmentExpression as LogicalExpression,\n};\n\nexport function MemberExpression(this: Printer, node: t.MemberExpression) {\n this.print(node.object);\n\n if (!node.computed && isMemberExpression(node.property)) {\n throw new TypeError(\"Got a MemberExpression for MemberExpression property\");\n }\n\n let computed = node.computed;\n // @ts-expect-error todo(flow->ts) maybe use specific literal types\n if (isLiteral(node.property) && typeof node.property.value === \"number\") {\n computed = true;\n }\n\n if (computed) {\n const exit = this.enterDelimited();\n this.token(\"[\");\n this.print(node.property);\n this.token(\"]\");\n exit();\n } else {\n this.token(\".\");\n this.print(node.property);\n }\n}\n\nexport function MetaProperty(this: Printer, node: t.MetaProperty) {\n this.print(node.meta);\n this.token(\".\");\n this.print(node.property);\n}\n\nexport function PrivateName(this: Printer, node: t.PrivateName) {\n this.token(\"#\");\n this.print(node.id);\n}\n\nexport function V8IntrinsicIdentifier(\n this: Printer,\n node: t.V8IntrinsicIdentifier,\n) {\n this.token(\"%\");\n this.word(node.name);\n}\n\nexport function ModuleExpression(this: Printer, node: t.ModuleExpression) {\n this.word(\"module\", true);\n this.space();\n this.token(\"{\");\n this.indent();\n const { body } = node;\n if (body.body.length || body.directives.length) {\n this.newline();\n }\n this.print(body);\n this.dedent();\n this.rightBrace(node);\n}\n"],"mapp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ChB,IAAI,CAAC0E,MAAM,CAAC,CAAC;EACb,IAAI,CAACC,UAAU,CAACpF,IAAI,CAAC;AACvB","ignoreList":[]}1 {"version":3,"names":["_t","require","_index","isCallExpression","isLiteral","isMemberExpression","isNewExpression","isPattern","UnaryExpression","node","operator","word","space","token","print","argument","DoExpression","async","body","ParenthesizedExpression","exit","enterDelimited","expression","rightParens","UpdateExpression","prefix","ConditionalExpression","test","consequent","alternate","NewExpression","parent","callee","format","minified","arguments","length","optional","typeArguments","typeParameters","tokenMap","endMatches","printList","shouldPrintTrailingComma","SequenceExpression","expressions","ThisExpression","Super","_shouldPrintDecoratorsBeforeExport","decoratorsBeforeExport","start","declaration","Decorator","newline","OptionalMemberExpression","computed","property","object","TypeError","value","OptionalCallExpression","CallExpression","Import","AwaitExpression","printTerminatorless","YieldExpression","delegate","EmptyStatement","semicolon","ExpressionStatement","tokenContext","TokenContext","expressionStatement","AssignmentPattern","left","type","typeAnnotation","right","AssignmentExpression","_endsWithDiv","BindExpression","MemberExpression","MetaProperty","meta","PrivateName","id","V8IntrinsicIdentifier","name","ModuleExpression","indent","directives","dedent","rightBrace"],"sources":["../../src/generators/expressions.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isCallExpression,\n isLiteral,\n isMemberExpression,\n isNewExpression,\n isPattern,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function UnaryExpression(this: Printer, node: t.UnaryExpression) {\n const { operator } = node;\n if (\n operator === \"void\" ||\n operator === \"delete\" ||\n operator === \"typeof\" ||\n // throwExpressions\n operator === \"throw\"\n ) {\n this.word(operator);\n this.space();\n } else {\n this.token(operator);\n }\n\n this.print(node.argument);\n}\n\nexport function DoExpression(this: Printer, node: t.DoExpression) {\n if (node.async) {\n this.word(\"async\", true);\n this.space();\n }\n this.word(\"do\");\n this.space();\n this.print(node.body);\n}\n\nexport function ParenthesizedExpression(\n this: Printer,\n node: t.ParenthesizedExpression,\n) {\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.print(node.expression);\n exit();\n this.rightParens(node);\n}\n\nexport function UpdateExpression(this: Printer, node: t.UpdateExpression) {\n if (node.prefix) {\n this.token(node.operator);\n this.print(node.argument);\n } else {\n this.print(node.argument, true);\n this.token(node.operator);\n }\n}\n\nexport function ConditionalExpression(\n this: Printer,\n node: t.ConditionalExpression,\n) {\n this.print(node.test);\n this.space();\n this.token(\"?\");\n this.space();\n this.print(node.consequent);\n this.space();\n this.token(\":\");\n this.space();\n this.print(node.alternate);\n}\n\nexport function NewExpression(\n this: Printer,\n node: t.NewExpression,\n parent: t.Node,\n) {\n this.word(\"new\");\n this.space();\n this.print(node.callee);\n if (\n this.format.minified &&\n node.arguments.length === 0 &&\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n !node.optional &&\n !isCallExpression(parent, { callee: node }) &&\n !isMemberExpression(parent) &&\n !isNewExpression(parent)\n ) {\n return;\n }\n\n this.print(node.typeArguments);\n if (!process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n this.print(node.typeParameters); // Legacy TS AST\n }\n\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n if (node.optional) {\n // TODO: This can never happen\n this.token(\"?.\");\n }\n\n if (\n node.arguments.length === 0 &&\n this.tokenMap &&\n !this.tokenMap.endMatches(node, \")\")\n ) {\n return;\n }\n\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments, this.shouldPrintTrailingComma(\")\"));\n exit();\n this.rightParens(node);\n}\n\nexport function SequenceExpression(this: Printer, node: t.SequenceExpression) {\n this.printList(node.expressions);\n}\n\nexport function ThisExpression(this: Printer) {\n this.word(\"this\");\n}\n\nexport function Super(this: Printer) {\n this.word(\"super\");\n}\n\nexport function _shouldPrintDecoratorsBeforeExport(\n this: Printer,\n node: t.ExportDeclaration & { declaration: t.ClassDeclaration },\n) {\n if (typeof this.format.decoratorsBeforeExport === \"boolean\") {\n return this.format.decoratorsBeforeExport;\n }\n return (\n typeof node.start === \"number\" && node.start === node.declaration.start\n );\n}\n\nexport function Decorator(this: Printer, node: t.Decorator) {\n this.token(\"@\");\n this.print(node.expression);\n this.newline();\n}\n\nexport function OptionalMemberExpression(\n this: Printer,\n node: t.OptionalMemberExpression,\n) {\n let { computed } = node;\n const { optional, property } = node;\n\n this.print(node.object);\n\n if (!computed && isMemberExpression(property)) {\n throw new TypeError(\"Got a MemberExpression for MemberExpression property\");\n }\n\n // @ts-expect-error todo(flow->ts) maybe instead of typeof check specific literal types?\n if (isLiteral(property) && typeof property.value === \"number\") {\n computed = true;\n }\n if (optional) {\n this.token(\"?.\");\n }\n\n if (computed) {\n this.token(\"[\");\n this.print(property);\n this.token(\"]\");\n } else {\n if (!optional) {\n this.token(\".\");\n }\n this.print(property);\n }\n}\n\nexport function OptionalCallExpression(\n this: Printer,\n node: t.OptionalCallExpression,\n) {\n this.print(node.callee);\n\n if (!process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n this.print(node.typeParameters); // legacy TS AST\n }\n\n if (node.optional) {\n this.token(\"?.\");\n }\n\n this.print(node.typeArguments);\n\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments);\n exit();\n this.rightParens(node);\n}\n\nexport function CallExpression(this: Printer, node: t.CallExpression) {\n this.print(node.callee);\n\n this.print(node.typeArguments);\n if (!process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n this.print(node.typeParameters); // legacy TS AST\n }\n this.token(\"(\");\n const exit = this.enterDelimited();\n this.printList(node.arguments, this.shouldPrintTrailingComma(\")\"));\n exit();\n this.rightParens(node);\n}\n\nexport function Import(this: Printer) {\n this.word(\"import\");\n}\n\nexport function AwaitExpression(this: Printer, node: t.AwaitExpression) {\n this.word(\"await\");\n\n if (node.argument) {\n this.space();\n this.printTerminatorless(node.argument);\n }\n}\n\nexport function YieldExpression(this: Printer, node: t.YieldExpression) {\n this.word(\"yield\", true);\n\n if (node.delegate) {\n this.token(\"*\");\n if (node.argument) {\n this.space();\n // line terminators are allowed after yield*\n this.print(node.argument);\n }\n } else {\n if (node.argument) {\n this.space();\n this.printTerminatorless(node.argument);\n }\n }\n}\n\nexport function EmptyStatement(this: Printer) {\n this.semicolon(true /* force */);\n}\n\nexport function ExpressionStatement(\n this: Printer,\n node: t.ExpressionStatement,\n) {\n this.tokenContext |= TokenContext.expressionStatement;\n this.print(node.expression);\n this.semicolon();\n}\n\nexport function AssignmentPattern(this: Printer, node: t.AssignmentPattern) {\n this.print(node.left);\n if (node.left.type === \"Identifier\" || isPattern(node.left)) {\n if (node.left.optional) this.token(\"?\");\n this.print(node.left.typeAnnotation);\n }\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.right);\n}\n\nexport function AssignmentExpression(\n this: Printer,\n node: t.AssignmentExpression | t.BinaryExpression | t.LogicalExpression,\n) {\n this.print(node.left);\n\n this.space();\n if (node.operator === \"in\" || node.operator === \"instanceof\") {\n this.word(node.operator);\n } else {\n this.token(node.operator);\n this._endsWithDiv = node.operator === \"/\";\n }\n this.space();\n\n this.print(node.right);\n}\n\nexport function BindExpression(this: Printer, node: t.BindExpression) {\n this.print(node.object);\n this.token(\"::\");\n this.print(node.callee);\n}\n\nexport {\n AssignmentExpression as BinaryExpression,\n AssignmentExpression as LogicalExpression,\n};\n\nexport function MemberExpression(this: Printer, node: t.MemberExpression) {\n this.print(node.object);\n\n if (!node.computed && isMemberExpression(node.property)) {\n throw new TypeError(\"Got a MemberExpression for MemberExpression property\");\n }\n\n let computed = node.computed;\n // @ts-expect-error todo(flow->ts) maybe use specific literal types\n if (isLiteral(node.property) && typeof node.property.value === \"number\") {\n computed = true;\n }\n\n if (computed) {\n const exit = this.enterDelimited();\n this.token(\"[\");\n this.print(node.property);\n this.token(\"]\");\n exit();\n } else {\n this.token(\".\");\n this.print(node.property);\n }\n}\n\nexport function MetaProperty(this: Printer, node: t.MetaProperty) {\n this.print(node.meta);\n this.token(\".\");\n this.print(node.property);\n}\n\nexport function PrivateName(this: Printer, node: t.PrivateName) {\n this.token(\"#\");\n this.print(node.id);\n}\n\nexport function V8IntrinsicIdentifier(\n this: Printer,\n node: t.V8IntrinsicIdentifier,\n) {\n this.token(\"%\");\n this.word(node.name);\n}\n\nexport function ModuleExpression(this: Printer, node: t.ModuleExpression) {\n this.word(\"module\", true);\n this.space();\n this.token(\"{\");\n this.indent();\n const { body } = node;\n if (body.body.length || body.directives.length) {\n this.newline();\n }\n this.print(body);\n this.dedent();\n this.rightBrace(node);\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAQA,IAAAC,MAAA,GAAAD,OAAA;AAAgD;EAP9CE,gBAAgB;EAChBC,SAAS;EACTC,kBAAkB;EAClBC,eAAe;EACfC;AAAS,IAAAP,EAAA;AAKJ,SAASQ,eAAeA,CAAgBC,IAAuB,EAAE;EACtE,MAAM;IAAEC;EAAS,CAAC,GAAGD,IAAI;EACzB,IACEC,QAAQ,KAAK,MAAM,IACnBA,QAAQ,KAAK,QAAQ,IACrBA,QAAQ,KAAK,QAAQ,IAErBA,QAAQ,KAAK,OAAO,EACpB;IACA,IAAI,CAACC,IAAI,CAACD,QAAQ,CAAC;IACnB,IAAI,CAACE,KAAK,CAAC,CAAC;EACd,CAAC,MAAM;IACL,IAAI,CAACC,KAAK,CAACH,QAAQ,CAAC;EACtB;EAEA,IAAI,CAACI,KAAK,CAACL,IAAI,CAACM,QAAQ,CAAC;AAC3B;AAEO,SAASC,YAAYA,CAAgBP,IAAoB,EAAE;EAChE,IAAIA,IAAI,CAACQ,KAAK,EAAE;IACd,IAAI,CAACN,IAAI,CAAC,OAAO,EAAE,IAAI,CAAC;IACxB,IAAI,CAACC,KAAK,CAAC,CAAC;EACd;EACA,IAAI,CAACD,IAAI,CAAC,IAAI,CAAC;EACf,IAAI,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CAACE,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC;EACzB,IAAI,CAACC,KAAK,CAAC,CAAC;EACZ,IAAI,CAACC,SAAK,IAAI,CAAC;EACf,IAAI,CAAC4E,MAAM,CAAC,CAAC;EACb,MAAM;IAAEvE;EAAK,CAAC,GAAGT,IAAI;EACrB,IAAIS,IAAI,CAACA,IAAI,CAACkB,MAAM,IAAIlB,IAAI,CAACwE,UAAU,CAACtD,MAAM,EAAE;IAC9C,IAAI,CAACiB,OAAO,CAAC,CAAC;EAChB;EACA,IAAI,CAACvC,KAAK,CAACI,IAAI,CAAC;EAChB,IAAI,CAACyE,MAAM,CAAC,CAAC;EACb,IAAI,CAACC,UAAU,CAACnF,IAAI,CAAC;AACvB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/flow.js
r0c6b92a r79a0317 418 418 } 419 419 function IntersectionTypeAnnotation(node) { 420 this.printJoin(node.types, { 421 separator: andSeparator 422 }); 420 this.printJoin(node.types, undefined, undefined, andSeparator); 423 421 } 424 422 function MixedTypeAnnotation() { … … 474 472 function TypeParameterInstantiation(node) { 475 473 this.tokenChar(60); 476 this.printList(node.params , {});474 this.printList(node.params); 477 475 this.tokenChar(62); 478 476 } … … 520 518 this.newline(); 521 519 this.space(); 522 this.printJoin(props, { 523 addNewlines(leading) { 524 if (leading && !props[0]) return 1; 525 }, 526 indent: true, 527 statement: true, 528 iterator: () => { 529 if (props.length !== 1 || node.inexact) { 530 this.tokenChar(44); 531 this.space(); 532 } 520 this.printJoin(props, true, true, undefined, undefined, function addNewlines(leading) { 521 if (leading && !props[0]) return 1; 522 }, () => { 523 if (props.length !== 1 || node.inexact) { 524 this.tokenChar(44); 525 this.space(); 533 526 } 534 527 }); … … 631 624 } 632 625 function UnionTypeAnnotation(node) { 633 this.printJoin(node.types, { 634 separator: orSeparator 635 }); 626 this.printJoin(node.types, undefined, undefined, orSeparator); 636 627 } 637 628 function TypeCastExpression(node) { -
imaps-frontend/node_modules/@babel/generator/lib/generators/flow.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_modules","_index","_types2","isDeclareExportDeclaration","isStatement","AnyTypeAnnotation","word","ArrayTypeAnnotation","node","print","elementType","token","BooleanTypeAnnotation","BooleanLiteralTypeAnnotation","value","NullLiteralTypeAnnotation","DeclareClass","parent","space","_interfaceish","DeclareFunction","id","typeAnnotation","predicate","semicolon","InferredPredicate","DeclaredPredicate","DeclareInterface","InterfaceDeclaration","DeclareModule","body","DeclareModuleExports","DeclareTypeAlias","TypeAlias","DeclareOpaqueType","OpaqueType","DeclareVariable","DeclareExportDeclaration","default","FlowExportDeclaration","call","DeclareExportAllDeclaration","ExportAllDeclaration","EnumDeclaration","enumExplicitType","context","name","hasExplicitType","enumBody","members","indent","newline","member","hasUnknownMembers","dedent","EnumBooleanBody","explicitType","EnumNumberBody","EnumStringBody","EnumSymbolBody","EnumDefaultedMember","enumInitializedMember","init","EnumBooleanMember","EnumNumberMember","EnumStringMember","declaration","declar","specifiers","length","printList","source","ExistsTypeAnnotation","FunctionTypeAnnotation","typeParameters","this","params","rest","type","method","returnType","FunctionTypeParam","optional","InterfaceExtends","_node$extends","extends","_node$mixins","_node$implements","mixins","implements","_variance","_node$variance","kind","variance","andSeparator","occurrenceCount","InterfaceTypeAnnotation","_node$extends2","IntersectionTypeAnnotation","printJoin","types"," separator","MixedTypeAnnotation","EmptyTypeAnnotation","NullableTypeAnnotation","NumberTypeAnnotation","StringTypeAnnotation","ThisTypeAnnotation","TupleTypeAnnotation","TypeofTypeAnnotation","argument","right","TypeAnnotation","tokenContext","TokenContext","arrowFlowReturnType","TypeParameterInstantiation","TypeParameter","bound","supertype","impltype","ObjectTypeAnnotation","exact","props","properties","callProperties","indexers","internalSlots","addNewlines","leading","statement","iterator","inexact","ObjectTypeInternalSlot","static","ObjectTypeCallProperty","ObjectTypeIndexer","key","ObjectTypeProperty","proto","ObjectTypeSpreadProperty","QualifiedTypeIdentifier","qualification","SymbolTypeAnnotation","orSeparator","UnionTypeAnnotation","TypeCastExpression","expression","Variance","VoidTypeAnnotation","IndexedAccessType","objectType","indexType","OptionalIndexedAccessType"],"sources":["../../src/generators/flow.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport { isDeclareExportDeclaration, isStatement } from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { ExportAllDeclaration } from \"./modules.ts\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function AnyTypeAnnotation(this: Printer) {\n this.word(\"any\");\n}\n\nexport function ArrayTypeAnnotation(\n this: Printer,\n node: t.ArrayTypeAnnotation,\n) {\n this.print(node.elementType, true);\n this.token(\"[\");\n this.token(\"]\");\n}\n\nexport function BooleanTypeAnnotation(this: Printer) {\n this.word(\"boolean\");\n}\n\nexport function BooleanLiteralTypeAnnotation(\n this: Printer,\n node: t.BooleanLiteralTypeAnnotation,\n) {\n this.word(node.value ? \"true\" : \"false\");\n}\n\nexport function NullLiteralTypeAnnotation(this: Printer) {\n this.word(\"null\");\n}\n\nexport function DeclareClass(\n this: Printer,\n node: t.DeclareClass,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"class\");\n this.space();\n this._interfaceish(node);\n}\n\nexport function DeclareFunction(\n this: Printer,\n node: t.DeclareFunction,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"function\");\n this.space();\n this.print(node.id);\n // @ts-ignore(Babel 7 vs Babel 8) TODO(Babel 8) Remove this comment, since we'll remove the Noop node\n this.print(node.id.typeAnnotation.typeAnnotation);\n\n if (node.predicate) {\n this.space();\n this.print(node.predicate);\n }\n\n this.semicolon();\n}\n\nexport function InferredPredicate(this: Printer) {\n this.token(\"%\");\n this.word(\"checks\");\n}\n\nexport function DeclaredPredicate(this: Printer, node: t.DeclaredPredicate) {\n this.token(\"%\");\n this.word(\"checks\");\n this.token(\"(\");\n this.print(node.value);\n this.token(\")\");\n}\n\nexport function DeclareInterface(this: Printer, node: t.DeclareInterface) {\n this.word(\"declare\");\n this.space();\n this.InterfaceDeclaration(node);\n}\n\nexport function DeclareModule(this: Printer, node: t.DeclareModule) {\n this.word(\"declare\");\n this.space();\n this.word(\"module\");\n this.space();\n this.print(node.id);\n this.space();\n this.print(node.body);\n}\n\nexport function DeclareModuleExports(\n this: Printer,\n node: t.DeclareModuleExports,\n) {\n this.word(\"declare\");\n this.space();\n this.word(\"module\");\n this.token(\".\");\n this.word(\"exports\");\n this.print(node.typeAnnotation);\n}\n\nexport function DeclareTypeAlias(this: Printer, node: t.DeclareTypeAlias) {\n this.word(\"declare\");\n this.space();\n this.TypeAlias(node);\n}\n\nexport function DeclareOpaqueType(\n this: Printer,\n node: t.DeclareOpaqueType,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.OpaqueType(node);\n}\n\nexport function DeclareVariable(\n this: Printer,\n node: t.DeclareVariable,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"var\");\n this.space();\n this.print(node.id);\n this.print(node.id.typeAnnotation);\n this.semicolon();\n}\n\nexport function DeclareExportDeclaration(\n this: Printer,\n node: t.DeclareExportDeclaration,\n) {\n this.word(\"declare\");\n this.space();\n this.word(\"export\");\n this.space();\n if (node.default) {\n this.word(\"default\");\n this.space();\n }\n\n FlowExportDeclaration.call(this, node);\n}\n\nexport function DeclareExportAllDeclaration(\n this: Printer,\n node: t.DeclareExportAllDeclaration,\n) {\n this.word(\"declare\");\n this.space();\n ExportAllDeclaration.call(this, node);\n}\n\nexport function EnumDeclaration(this: Printer, node: t.EnumDeclaration) {\n const { id, body } = node;\n this.word(\"enum\");\n this.space();\n this.print(id);\n this.print(body);\n}\n\nfunction enumExplicitType(\n context: Printer,\n name: string,\n hasExplicitType: boolean,\n) {\n if (hasExplicitType) {\n context.space();\n context.word(\"of\");\n context.space();\n context.word(name);\n }\n context.space();\n}\n\nfunction enumBody(context: Printer, node: t.EnumBody) {\n const { members } = node;\n context.token(\"{\");\n context.indent();\n context.newline();\n for (const member of members) {\n context.print(member);\n context.newline();\n }\n if (node.hasUnknownMembers) {\n context.token(\"...\");\n context.newline();\n }\n context.dedent();\n context.token(\"}\");\n}\n\nexport function EnumBooleanBody(this: Printer, node: t.EnumBooleanBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"boolean\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumNumberBody(this: Printer, node: t.EnumNumberBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"number\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumStringBody(this: Printer, node: t.EnumStringBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"string\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumSymbolBody(this: Printer, node: t.EnumSymbolBody) {\n enumExplicitType(this, \"symbol\", true);\n enumBody(this, node);\n}\n\nexport function EnumDefaultedMember(\n this: Printer,\n node: t.EnumDefaultedMember,\n) {\n const { id } = node;\n this.print(id);\n this.token(\",\");\n}\n\nfunction enumInitializedMember(\n context: Printer,\n node: t.EnumBooleanMember | t.EnumNumberMember | t.EnumStringMember,\n) {\n context.print(node.id);\n context.space();\n context.token(\"=\");\n context.space();\n context.print(node.init);\n context.token(\",\");\n}\n\nexport function EnumBooleanMember(this: Printer, node: t.EnumBooleanMember) {\n enumInitializedMember(this, node);\n}\n\nexport function EnumNumberMember(this: Printer, node: t.EnumNumberMember) {\n enumInitializedMember(this, node);\n}\n\nexport function EnumStringMember(this: Printer, node: t.EnumStringMember) {\n enumInitializedMember(this, node);\n}\n\nfunction FlowExportDeclaration(\n this: Printer,\n node: t.DeclareExportDeclaration,\n) {\n if (node.declaration) {\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n } else {\n this.token(\"{\");\n if (node.specifiers.length) {\n this.space();\n this.printList(node.specifiers);\n this.space();\n }\n this.token(\"}\");\n\n if (node.source) {\n this.space();\n this.word(\"from\");\n this.space();\n this.print(node.source);\n }\n\n this.semicolon();\n }\n}\n\nexport function ExistsTypeAnnotation(this: Printer) {\n this.token(\"*\");\n}\n\nexport function FunctionTypeAnnotation(\n this: Printer,\n node: t.FunctionTypeAnnotation,\n parent?: t.Node,\n) {\n this.print(node.typeParameters);\n this.token(\"(\");\n\n if (node.this) {\n this.word(\"this\");\n this.token(\":\");\n this.space();\n this.print(node.this.typeAnnotation);\n if (node.params.length || node.rest) {\n this.token(\",\");\n this.space();\n }\n }\n\n this.printList(node.params);\n\n if (node.rest) {\n if (node.params.length) {\n this.token(\",\");\n this.space();\n }\n this.token(\"...\");\n this.print(node.rest);\n }\n\n this.token(\")\");\n\n // this node type is overloaded, not sure why but it makes it EXTREMELY annoying\n\n const type = parent?.type;\n if (\n type != null &&\n (type === \"ObjectTypeCallProperty\" ||\n type === \"ObjectTypeInternalSlot\" ||\n type === \"DeclareFunction\" ||\n (type === \"ObjectTypeProperty\" && parent.method))\n ) {\n this.token(\":\");\n } else {\n this.space();\n this.token(\"=>\");\n }\n\n this.space();\n this.print(node.returnType);\n}\n\nexport function FunctionTypeParam(this: Printer, node: t.FunctionTypeParam) {\n this.print(node.name);\n if (node.optional) this.token(\"?\");\n if (node.name) {\n this.token(\":\");\n this.space();\n }\n this.print(node.typeAnnotation);\n}\n\nexport function InterfaceExtends(this: Printer, node: t.InterfaceExtends) {\n this.print(node.id);\n this.print(node.typeParameters, true);\n}\n\nexport {\n InterfaceExtends as ClassImplements,\n InterfaceExtends as GenericTypeAnnotation,\n};\n\nexport function _interfaceish(\n this: Printer,\n node: t.InterfaceDeclaration | t.DeclareInterface | t.DeclareClass,\n) {\n this.print(node.id);\n this.print(node.typeParameters);\n if (node.extends?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(node.extends);\n }\n if (node.type === \"DeclareClass\") {\n if (node.mixins?.length) {\n this.space();\n this.word(\"mixins\");\n this.space();\n this.printList(node.mixins);\n }\n if (node.implements?.length) {\n this.space();\n this.word(\"implements\");\n this.space();\n this.printList(node.implements);\n }\n }\n this.space();\n this.print(node.body);\n}\n\nexport function _variance(\n this: Printer,\n node:\n | t.TypeParameter\n | t.ObjectTypeIndexer\n | t.ObjectTypeProperty\n | t.ClassProperty\n | t.ClassPrivateProperty\n | t.ClassAccessorProperty,\n) {\n const kind = node.variance?.kind;\n if (kind != null) {\n if (kind === \"plus\") {\n this.token(\"+\");\n } else if (kind === \"minus\") {\n this.token(\"-\");\n }\n }\n}\n\nexport function InterfaceDeclaration(\n this: Printer,\n node: t.InterfaceDeclaration | t.DeclareInterface,\n) {\n this.word(\"interface\");\n this.space();\n this._interfaceish(node);\n}\n\nfunction andSeparator(this: Printer, occurrenceCount: number) {\n this.space();\n this.token(\"&\", false, occurrenceCount);\n this.space();\n}\n\nexport function InterfaceTypeAnnotation(\n this: Printer,\n node: t.InterfaceTypeAnnotation,\n) {\n this.word(\"interface\");\n if (node.extends?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(node.extends);\n }\n this.space();\n this.print(node.body);\n}\n\nexport function IntersectionTypeAnnotation(\n this: Printer,\n node: t.IntersectionTypeAnnotation,\n) {\n this.printJoin(node.types, { separator: andSeparator });\n}\n\nexport function MixedTypeAnnotation(this: Printer) {\n this.word(\"mixed\");\n}\n\nexport function EmptyTypeAnnotation(this: Printer) {\n this.word(\"empty\");\n}\n\nexport function NullableTypeAnnotation(\n this: Printer,\n node: t.NullableTypeAnnotation,\n) {\n this.token(\"?\");\n this.print(node.typeAnnotation);\n}\n\nexport {\n NumericLiteral as NumberLiteralTypeAnnotation,\n StringLiteral as StringLiteralTypeAnnotation,\n} from \"./types.ts\";\n\nexport function NumberTypeAnnotation(this: Printer) {\n this.word(\"number\");\n}\n\nexport function StringTypeAnnotation(this: Printer) {\n this.word(\"string\");\n}\n\nexport function ThisTypeAnnotation(this: Printer) {\n this.word(\"this\");\n}\n\nexport function TupleTypeAnnotation(\n this: Printer,\n node: t.TupleTypeAnnotation,\n) {\n this.token(\"[\");\n this.printList(node.types);\n this.token(\"]\");\n}\n\nexport function TypeofTypeAnnotation(\n this: Printer,\n node: t.TypeofTypeAnnotation,\n) {\n this.word(\"typeof\");\n this.space();\n this.print(node.argument);\n}\n\nexport function TypeAlias(\n this: Printer,\n node: t.TypeAlias | t.DeclareTypeAlias,\n) {\n this.word(\"type\");\n this.space();\n this.print(node.id);\n this.print(node.typeParameters);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.right);\n this.semicolon();\n}\n\nexport function TypeAnnotation(\n this: Printer,\n node: t.TypeAnnotation,\n parent: t.Node,\n) {\n this.token(\":\");\n this.space();\n if (parent.type === \"ArrowFunctionExpression\") {\n this.tokenContext |= TokenContext.arrowFlowReturnType;\n } else if (\n // @ts-expect-error todo(flow->ts) can this be removed? `.optional` looks to be not existing property\n node.optional\n ) {\n this.token(\"?\");\n }\n this.print(node.typeAnnotation);\n}\n\nexport function TypeParameterInstantiation(\n this: Printer,\n node: t.TypeParameterInstantiation,\n): void {\n this.token(\"<\");\n this.printList(node.params, {});\n this.token(\">\");\n}\n\nexport { TypeParameterInstantiation as TypeParameterDeclaration };\n\nexport function TypeParameter(this: Printer, node: t.TypeParameter) {\n this._variance(node);\n\n this.word(node.name);\n\n if (node.bound) {\n this.print(node.bound);\n }\n\n if (node.default) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.default);\n }\n}\n\nexport function OpaqueType(\n this: Printer,\n node: t.OpaqueType | t.DeclareOpaqueType,\n) {\n this.word(\"opaque\");\n this.space();\n this.word(\"type\");\n this.space();\n this.print(node.id);\n this.print(node.typeParameters);\n if (node.supertype) {\n this.token(\":\");\n this.space();\n this.print(node.supertype);\n }\n\n if (node.impltype) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.impltype);\n }\n this.semicolon();\n}\n\nexport function ObjectTypeAnnotation(\n this: Printer,\n node: t.ObjectTypeAnnotation,\n) {\n if (node.exact) {\n this.token(\"{|\");\n } else {\n this.token(\"{\");\n }\n\n // TODO: remove the array fallbacks and instead enforce the types to require an array\n const props = [\n ...node.properties,\n ...(node.callProperties || []),\n ...(node.indexers || []),\n ...(node.internalSlots || []),\n ];\n\n if (props.length) {\n this.newline();\n\n this.space();\n\n this.printJoin(props, {\n addNewlines(leading) {\n if (leading && !props[0]) return 1;\n },\n indent: true,\n statement: true,\n iterator: () => {\n if (props.length !== 1 || node.inexact) {\n this.token(\",\");\n this.space();\n }\n },\n });\n\n this.space();\n }\n\n if (node.inexact) {\n this.indent();\n this.token(\"...\");\n if (props.length) {\n this.newline();\n }\n this.dedent();\n }\n\n if (node.exact) {\n this.token(\"|}\");\n } else {\n this.token(\"}\");\n }\n}\n\nexport function ObjectTypeInternalSlot(\n this: Printer,\n node: t.ObjectTypeInternalSlot,\n) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.token(\"[\");\n this.token(\"[\");\n this.print(node.id);\n this.token(\"]\");\n this.token(\"]\");\n if (node.optional) this.token(\"?\");\n if (!node.method) {\n this.token(\":\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeCallProperty(\n this: Printer,\n node: t.ObjectTypeCallProperty,\n) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeIndexer(this: Printer, node: t.ObjectTypeIndexer) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this._variance(node);\n this.token(\"[\");\n if (node.id) {\n this.print(node.id);\n this.token(\":\");\n this.space();\n }\n this.print(node.key);\n this.token(\"]\");\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ObjectTypeProperty(this: Printer, node: t.ObjectTypeProperty) {\n if (node.proto) {\n this.word(\"proto\");\n this.space();\n }\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n if (node.kind === \"get\" || node.kind === \"set\") {\n this.word(node.kind);\n this.space();\n }\n this._variance(node);\n this.print(node.key);\n if (node.optional) this.token(\"?\");\n if (!node.method) {\n this.token(\":\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeSpreadProperty(\n this: Printer,\n node: t.ObjectTypeSpreadProperty,\n) {\n this.token(\"...\");\n this.print(node.argument);\n}\n\nexport function QualifiedTypeIdentifier(\n this: Printer,\n node: t.QualifiedTypeIdentifier,\n) {\n this.print(node.qualification);\n this.token(\".\");\n this.print(node.id);\n}\n\nexport function SymbolTypeAnnotation(this: Printer) {\n this.word(\"symbol\");\n}\n\nfunction orSeparator(this: Printer, occurrenceCount: number) {\n this.space();\n this.token(\"|\", false, occurrenceCount);\n this.space();\n}\n\nexport function UnionTypeAnnotation(\n this: Printer,\n node: t.UnionTypeAnnotation,\n) {\n this.printJoin(node.types, { separator: orSeparator });\n}\n\nexport function TypeCastExpression(this: Printer, node: t.TypeCastExpression) {\n this.token(\"(\");\n this.print(node.expression);\n this.print(node.typeAnnotation);\n this.token(\")\");\n}\n\nexport function Variance(this: Printer, node: t.Variance) {\n if (node.kind === \"plus\") {\n this.token(\"+\");\n } else {\n this.token(\"-\");\n }\n}\n\nexport function VoidTypeAnnotation(this: Printer) {\n this.word(\"void\");\n}\n\nexport function IndexedAccessType(this: Printer, node: t.IndexedAccessType) {\n this.print(node.objectType, true);\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n\nexport function OptionalIndexedAccessType(\n this: Printer,\n node: t.OptionalIndexedAccessType,\n) {\n this.print(node.objectType);\n if (node.optional) {\n this.token(\"?.\");\n }\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAEA,IAAAC,QAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAqdA,IAAAG,OAAA,GAAAH,OAAA;AAG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;EAC1B,IAAI,CAAC7I,SAAK,GAAI,CAAC;AACjB","ignoreList":[]}1 {"version":3,"names":["_t","require","_modules","_index","_types2","isDeclareExportDeclaration","isStatement","AnyTypeAnnotation","word","ArrayTypeAnnotation","node","print","elementType","token","BooleanTypeAnnotation","BooleanLiteralTypeAnnotation","value","NullLiteralTypeAnnotation","DeclareClass","parent","space","_interfaceish","DeclareFunction","id","typeAnnotation","predicate","semicolon","InferredPredicate","DeclaredPredicate","DeclareInterface","InterfaceDeclaration","DeclareModule","body","DeclareModuleExports","DeclareTypeAlias","TypeAlias","DeclareOpaqueType","OpaqueType","DeclareVariable","DeclareExportDeclaration","default","FlowExportDeclaration","call","DeclareExportAllDeclaration","ExportAllDeclaration","EnumDeclaration","enumExplicitType","context","name","hasExplicitType","enumBody","members","indent","newline","member","hasUnknownMembers","dedent","EnumBooleanBody","explicitType","EnumNumberBody","EnumStringBody","EnumSymbolBody","EnumDefaultedMember","enumInitializedMember","init","EnumBooleanMember","EnumNumberMember","EnumStringMember","declaration","declar","specifiers","length","printList","source","ExistsTypeAnnotation","FunctionTypeAnnotation","typeParameters","this","params","rest","type","method","returnType","FunctionTypeParam","optional","InterfaceExtends","_node$extends","extends","_node$mixins","_node$implements","mixins","implements","_variance","_node$variance","kind","variance","andSeparator","occurrenceCount","InterfaceTypeAnnotation","_node$extends2","IntersectionTypeAnnotation","printJoin","types","undefined","MixedTypeAnnotation","EmptyTypeAnnotation","NullableTypeAnnotation","NumberTypeAnnotation","StringTypeAnnotation","ThisTypeAnnotation","TupleTypeAnnotation","TypeofTypeAnnotation","argument","right","TypeAnnotation","tokenContext","TokenContext","arrowFlowReturnType","TypeParameterInstantiation","TypeParameter","bound","supertype","impltype","ObjectTypeAnnotation","exact","props","properties","callProperties","indexers","internalSlots","addNewlines","leading","inexact","ObjectTypeInternalSlot","static","ObjectTypeCallProperty","ObjectTypeIndexer","key","ObjectTypeProperty","proto","ObjectTypeSpreadProperty","QualifiedTypeIdentifier","qualification","SymbolTypeAnnotation","orSeparator","UnionTypeAnnotation","TypeCastExpression","expression","Variance","VoidTypeAnnotation","IndexedAccessType","objectType","indexType","OptionalIndexedAccessType"],"sources":["../../src/generators/flow.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport { isDeclareExportDeclaration, isStatement } from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { ExportAllDeclaration } from \"./modules.ts\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function AnyTypeAnnotation(this: Printer) {\n this.word(\"any\");\n}\n\nexport function ArrayTypeAnnotation(\n this: Printer,\n node: t.ArrayTypeAnnotation,\n) {\n this.print(node.elementType, true);\n this.token(\"[\");\n this.token(\"]\");\n}\n\nexport function BooleanTypeAnnotation(this: Printer) {\n this.word(\"boolean\");\n}\n\nexport function BooleanLiteralTypeAnnotation(\n this: Printer,\n node: t.BooleanLiteralTypeAnnotation,\n) {\n this.word(node.value ? \"true\" : \"false\");\n}\n\nexport function NullLiteralTypeAnnotation(this: Printer) {\n this.word(\"null\");\n}\n\nexport function DeclareClass(\n this: Printer,\n node: t.DeclareClass,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"class\");\n this.space();\n this._interfaceish(node);\n}\n\nexport function DeclareFunction(\n this: Printer,\n node: t.DeclareFunction,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"function\");\n this.space();\n this.print(node.id);\n // @ts-ignore(Babel 7 vs Babel 8) TODO(Babel 8) Remove this comment, since we'll remove the Noop node\n this.print(node.id.typeAnnotation.typeAnnotation);\n\n if (node.predicate) {\n this.space();\n this.print(node.predicate);\n }\n\n this.semicolon();\n}\n\nexport function InferredPredicate(this: Printer) {\n this.token(\"%\");\n this.word(\"checks\");\n}\n\nexport function DeclaredPredicate(this: Printer, node: t.DeclaredPredicate) {\n this.token(\"%\");\n this.word(\"checks\");\n this.token(\"(\");\n this.print(node.value);\n this.token(\")\");\n}\n\nexport function DeclareInterface(this: Printer, node: t.DeclareInterface) {\n this.word(\"declare\");\n this.space();\n this.InterfaceDeclaration(node);\n}\n\nexport function DeclareModule(this: Printer, node: t.DeclareModule) {\n this.word(\"declare\");\n this.space();\n this.word(\"module\");\n this.space();\n this.print(node.id);\n this.space();\n this.print(node.body);\n}\n\nexport function DeclareModuleExports(\n this: Printer,\n node: t.DeclareModuleExports,\n) {\n this.word(\"declare\");\n this.space();\n this.word(\"module\");\n this.token(\".\");\n this.word(\"exports\");\n this.print(node.typeAnnotation);\n}\n\nexport function DeclareTypeAlias(this: Printer, node: t.DeclareTypeAlias) {\n this.word(\"declare\");\n this.space();\n this.TypeAlias(node);\n}\n\nexport function DeclareOpaqueType(\n this: Printer,\n node: t.DeclareOpaqueType,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.OpaqueType(node);\n}\n\nexport function DeclareVariable(\n this: Printer,\n node: t.DeclareVariable,\n parent: t.Node,\n) {\n if (!isDeclareExportDeclaration(parent)) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"var\");\n this.space();\n this.print(node.id);\n this.print(node.id.typeAnnotation);\n this.semicolon();\n}\n\nexport function DeclareExportDeclaration(\n this: Printer,\n node: t.DeclareExportDeclaration,\n) {\n this.word(\"declare\");\n this.space();\n this.word(\"export\");\n this.space();\n if (node.default) {\n this.word(\"default\");\n this.space();\n }\n\n FlowExportDeclaration.call(this, node);\n}\n\nexport function DeclareExportAllDeclaration(\n this: Printer,\n node: t.DeclareExportAllDeclaration,\n) {\n this.word(\"declare\");\n this.space();\n ExportAllDeclaration.call(this, node);\n}\n\nexport function EnumDeclaration(this: Printer, node: t.EnumDeclaration) {\n const { id, body } = node;\n this.word(\"enum\");\n this.space();\n this.print(id);\n this.print(body);\n}\n\nfunction enumExplicitType(\n context: Printer,\n name: string,\n hasExplicitType: boolean,\n) {\n if (hasExplicitType) {\n context.space();\n context.word(\"of\");\n context.space();\n context.word(name);\n }\n context.space();\n}\n\nfunction enumBody(context: Printer, node: t.EnumBody) {\n const { members } = node;\n context.token(\"{\");\n context.indent();\n context.newline();\n for (const member of members) {\n context.print(member);\n context.newline();\n }\n if (node.hasUnknownMembers) {\n context.token(\"...\");\n context.newline();\n }\n context.dedent();\n context.token(\"}\");\n}\n\nexport function EnumBooleanBody(this: Printer, node: t.EnumBooleanBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"boolean\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumNumberBody(this: Printer, node: t.EnumNumberBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"number\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumStringBody(this: Printer, node: t.EnumStringBody) {\n const { explicitType } = node;\n enumExplicitType(this, \"string\", explicitType);\n enumBody(this, node);\n}\n\nexport function EnumSymbolBody(this: Printer, node: t.EnumSymbolBody) {\n enumExplicitType(this, \"symbol\", true);\n enumBody(this, node);\n}\n\nexport function EnumDefaultedMember(\n this: Printer,\n node: t.EnumDefaultedMember,\n) {\n const { id } = node;\n this.print(id);\n this.token(\",\");\n}\n\nfunction enumInitializedMember(\n context: Printer,\n node: t.EnumBooleanMember | t.EnumNumberMember | t.EnumStringMember,\n) {\n context.print(node.id);\n context.space();\n context.token(\"=\");\n context.space();\n context.print(node.init);\n context.token(\",\");\n}\n\nexport function EnumBooleanMember(this: Printer, node: t.EnumBooleanMember) {\n enumInitializedMember(this, node);\n}\n\nexport function EnumNumberMember(this: Printer, node: t.EnumNumberMember) {\n enumInitializedMember(this, node);\n}\n\nexport function EnumStringMember(this: Printer, node: t.EnumStringMember) {\n enumInitializedMember(this, node);\n}\n\nfunction FlowExportDeclaration(\n this: Printer,\n node: t.DeclareExportDeclaration,\n) {\n if (node.declaration) {\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n } else {\n this.token(\"{\");\n if (node.specifiers.length) {\n this.space();\n this.printList(node.specifiers);\n this.space();\n }\n this.token(\"}\");\n\n if (node.source) {\n this.space();\n this.word(\"from\");\n this.space();\n this.print(node.source);\n }\n\n this.semicolon();\n }\n}\n\nexport function ExistsTypeAnnotation(this: Printer) {\n this.token(\"*\");\n}\n\nexport function FunctionTypeAnnotation(\n this: Printer,\n node: t.FunctionTypeAnnotation,\n parent?: t.Node,\n) {\n this.print(node.typeParameters);\n this.token(\"(\");\n\n if (node.this) {\n this.word(\"this\");\n this.token(\":\");\n this.space();\n this.print(node.this.typeAnnotation);\n if (node.params.length || node.rest) {\n this.token(\",\");\n this.space();\n }\n }\n\n this.printList(node.params);\n\n if (node.rest) {\n if (node.params.length) {\n this.token(\",\");\n this.space();\n }\n this.token(\"...\");\n this.print(node.rest);\n }\n\n this.token(\")\");\n\n // this node type is overloaded, not sure why but it makes it EXTREMELY annoying\n\n const type = parent?.type;\n if (\n type != null &&\n (type === \"ObjectTypeCallProperty\" ||\n type === \"ObjectTypeInternalSlot\" ||\n type === \"DeclareFunction\" ||\n (type === \"ObjectTypeProperty\" && parent.method))\n ) {\n this.token(\":\");\n } else {\n this.space();\n this.token(\"=>\");\n }\n\n this.space();\n this.print(node.returnType);\n}\n\nexport function FunctionTypeParam(this: Printer, node: t.FunctionTypeParam) {\n this.print(node.name);\n if (node.optional) this.token(\"?\");\n if (node.name) {\n this.token(\":\");\n this.space();\n }\n this.print(node.typeAnnotation);\n}\n\nexport function InterfaceExtends(this: Printer, node: t.InterfaceExtends) {\n this.print(node.id);\n this.print(node.typeParameters, true);\n}\n\nexport {\n InterfaceExtends as ClassImplements,\n InterfaceExtends as GenericTypeAnnotation,\n};\n\nexport function _interfaceish(\n this: Printer,\n node: t.InterfaceDeclaration | t.DeclareInterface | t.DeclareClass,\n) {\n this.print(node.id);\n this.print(node.typeParameters);\n if (node.extends?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(node.extends);\n }\n if (node.type === \"DeclareClass\") {\n if (node.mixins?.length) {\n this.space();\n this.word(\"mixins\");\n this.space();\n this.printList(node.mixins);\n }\n if (node.implements?.length) {\n this.space();\n this.word(\"implements\");\n this.space();\n this.printList(node.implements);\n }\n }\n this.space();\n this.print(node.body);\n}\n\nexport function _variance(\n this: Printer,\n node:\n | t.TypeParameter\n | t.ObjectTypeIndexer\n | t.ObjectTypeProperty\n | t.ClassProperty\n | t.ClassPrivateProperty\n | t.ClassAccessorProperty,\n) {\n const kind = node.variance?.kind;\n if (kind != null) {\n if (kind === \"plus\") {\n this.token(\"+\");\n } else if (kind === \"minus\") {\n this.token(\"-\");\n }\n }\n}\n\nexport function InterfaceDeclaration(\n this: Printer,\n node: t.InterfaceDeclaration | t.DeclareInterface,\n) {\n this.word(\"interface\");\n this.space();\n this._interfaceish(node);\n}\n\nfunction andSeparator(this: Printer, occurrenceCount: number) {\n this.space();\n this.token(\"&\", false, occurrenceCount);\n this.space();\n}\n\nexport function InterfaceTypeAnnotation(\n this: Printer,\n node: t.InterfaceTypeAnnotation,\n) {\n this.word(\"interface\");\n if (node.extends?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(node.extends);\n }\n this.space();\n this.print(node.body);\n}\n\nexport function IntersectionTypeAnnotation(\n this: Printer,\n node: t.IntersectionTypeAnnotation,\n) {\n this.printJoin(node.types, undefined, undefined, andSeparator);\n}\n\nexport function MixedTypeAnnotation(this: Printer) {\n this.word(\"mixed\");\n}\n\nexport function EmptyTypeAnnotation(this: Printer) {\n this.word(\"empty\");\n}\n\nexport function NullableTypeAnnotation(\n this: Printer,\n node: t.NullableTypeAnnotation,\n) {\n this.token(\"?\");\n this.print(node.typeAnnotation);\n}\n\nexport {\n NumericLiteral as NumberLiteralTypeAnnotation,\n StringLiteral as StringLiteralTypeAnnotation,\n} from \"./types.ts\";\n\nexport function NumberTypeAnnotation(this: Printer) {\n this.word(\"number\");\n}\n\nexport function StringTypeAnnotation(this: Printer) {\n this.word(\"string\");\n}\n\nexport function ThisTypeAnnotation(this: Printer) {\n this.word(\"this\");\n}\n\nexport function TupleTypeAnnotation(\n this: Printer,\n node: t.TupleTypeAnnotation,\n) {\n this.token(\"[\");\n this.printList(node.types);\n this.token(\"]\");\n}\n\nexport function TypeofTypeAnnotation(\n this: Printer,\n node: t.TypeofTypeAnnotation,\n) {\n this.word(\"typeof\");\n this.space();\n this.print(node.argument);\n}\n\nexport function TypeAlias(\n this: Printer,\n node: t.TypeAlias | t.DeclareTypeAlias,\n) {\n this.word(\"type\");\n this.space();\n this.print(node.id);\n this.print(node.typeParameters);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.right);\n this.semicolon();\n}\n\nexport function TypeAnnotation(\n this: Printer,\n node: t.TypeAnnotation,\n parent: t.Node,\n) {\n this.token(\":\");\n this.space();\n if (parent.type === \"ArrowFunctionExpression\") {\n this.tokenContext |= TokenContext.arrowFlowReturnType;\n } else if (\n // @ts-expect-error todo(flow->ts) can this be removed? `.optional` looks to be not existing property\n node.optional\n ) {\n this.token(\"?\");\n }\n this.print(node.typeAnnotation);\n}\n\nexport function TypeParameterInstantiation(\n this: Printer,\n node: t.TypeParameterInstantiation,\n): void {\n this.token(\"<\");\n this.printList(node.params);\n this.token(\">\");\n}\n\nexport { TypeParameterInstantiation as TypeParameterDeclaration };\n\nexport function TypeParameter(this: Printer, node: t.TypeParameter) {\n this._variance(node);\n\n this.word(node.name);\n\n if (node.bound) {\n this.print(node.bound);\n }\n\n if (node.default) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.default);\n }\n}\n\nexport function OpaqueType(\n this: Printer,\n node: t.OpaqueType | t.DeclareOpaqueType,\n) {\n this.word(\"opaque\");\n this.space();\n this.word(\"type\");\n this.space();\n this.print(node.id);\n this.print(node.typeParameters);\n if (node.supertype) {\n this.token(\":\");\n this.space();\n this.print(node.supertype);\n }\n\n if (node.impltype) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.impltype);\n }\n this.semicolon();\n}\n\nexport function ObjectTypeAnnotation(\n this: Printer,\n node: t.ObjectTypeAnnotation,\n) {\n if (node.exact) {\n this.token(\"{|\");\n } else {\n this.token(\"{\");\n }\n\n // TODO: remove the array fallbacks and instead enforce the types to require an array\n const props = [\n ...node.properties,\n ...(node.callProperties || []),\n ...(node.indexers || []),\n ...(node.internalSlots || []),\n ];\n\n if (props.length) {\n this.newline();\n\n this.space();\n\n this.printJoin(\n props,\n true,\n true,\n undefined,\n undefined,\n function addNewlines(leading) {\n if (leading && !props[0]) return 1;\n },\n () => {\n if (props.length !== 1 || node.inexact) {\n this.token(\",\");\n this.space();\n }\n },\n );\n\n this.space();\n }\n\n if (node.inexact) {\n this.indent();\n this.token(\"...\");\n if (props.length) {\n this.newline();\n }\n this.dedent();\n }\n\n if (node.exact) {\n this.token(\"|}\");\n } else {\n this.token(\"}\");\n }\n}\n\nexport function ObjectTypeInternalSlot(\n this: Printer,\n node: t.ObjectTypeInternalSlot,\n) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.token(\"[\");\n this.token(\"[\");\n this.print(node.id);\n this.token(\"]\");\n this.token(\"]\");\n if (node.optional) this.token(\"?\");\n if (!node.method) {\n this.token(\":\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeCallProperty(\n this: Printer,\n node: t.ObjectTypeCallProperty,\n) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeIndexer(this: Printer, node: t.ObjectTypeIndexer) {\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n this._variance(node);\n this.token(\"[\");\n if (node.id) {\n this.print(node.id);\n this.token(\":\");\n this.space();\n }\n this.print(node.key);\n this.token(\"]\");\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ObjectTypeProperty(this: Printer, node: t.ObjectTypeProperty) {\n if (node.proto) {\n this.word(\"proto\");\n this.space();\n }\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n if (node.kind === \"get\" || node.kind === \"set\") {\n this.word(node.kind);\n this.space();\n }\n this._variance(node);\n this.print(node.key);\n if (node.optional) this.token(\"?\");\n if (!node.method) {\n this.token(\":\");\n this.space();\n }\n this.print(node.value);\n}\n\nexport function ObjectTypeSpreadProperty(\n this: Printer,\n node: t.ObjectTypeSpreadProperty,\n) {\n this.token(\"...\");\n this.print(node.argument);\n}\n\nexport function QualifiedTypeIdentifier(\n this: Printer,\n node: t.QualifiedTypeIdentifier,\n) {\n this.print(node.qualification);\n this.token(\".\");\n this.print(node.id);\n}\n\nexport function SymbolTypeAnnotation(this: Printer) {\n this.word(\"symbol\");\n}\n\nfunction orSeparator(this: Printer, occurrenceCount: number) {\n this.space();\n this.token(\"|\", false, occurrenceCount);\n this.space();\n}\n\nexport function UnionTypeAnnotation(\n this: Printer,\n node: t.UnionTypeAnnotation,\n) {\n this.printJoin(node.types, undefined, undefined, orSeparator);\n}\n\nexport function TypeCastExpression(this: Printer, node: t.TypeCastExpression) {\n this.token(\"(\");\n this.print(node.expression);\n this.print(node.typeAnnotation);\n this.token(\")\");\n}\n\nexport function Variance(this: Printer, node: t.Variance) {\n if (node.kind === \"plus\") {\n this.token(\"+\");\n } else {\n this.token(\"-\");\n }\n}\n\nexport function VoidTypeAnnotation(this: Printer) {\n this.word(\"void\");\n}\n\nexport function IndexedAccessType(this: Printer, node: t.IndexedAccessType) {\n this.print(node.objectType, true);\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n\nexport function OptionalIndexedAccessType(\n this: Printer,\n node: t.OptionalIndexedAccessType,\n) {\n this.print(node.objectType);\n if (node.optional) {\n this.token(\"?.\");\n }\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAEA,IAAAC,QAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAqdA,IAAA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,SAAK,GAAI,CAAC;AACjB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/jsx.js
r0c6b92a r79a0317 81 81 this.tokenChar(60); 82 82 this.print(node.name); 83 this.print(node.typeParameters); 83 { 84 if (node.typeArguments) { 85 this.print(node.typeArguments); 86 } 87 this.print(node.typeParameters); 88 } 84 89 if (node.attributes.length > 0) { 85 90 this.space(); 86 this.printJoin(node.attributes, { 87 separator: spaceSeparator 88 }); 91 this.printJoin(node.attributes, undefined, undefined, spaceSeparator); 89 92 } 90 93 if (node.selfClosing) { -
imaps-frontend/node_modules/@babel/generator/lib/generators/jsx.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["JSXAttribute","node","print","name","value","token","JSXIdentifier","word","JSXNamespacedName","namespace","JSXMemberExpression","object","property","JSXSpreadAttribute","argument","rightBrace","JSXExpressionContainer","expression","JSXSpreadChild","JSXText","raw","getPossibleRaw","undefined","JSXElement","open","openingElement","selfClosing","indent","child","children","dedent","closingElement","spaceSeparator","space","JSXOpeningElement","type Parameters","attributes","length","printJoin","separator","JSXClosingElement","JSXEmptyExpression","printInnerComments","JSXFragment","openingFragment","closingFragment","JSXOpeningFragment","JSXClosingFragment"],"sources":["../../src/generators/jsx.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function JSXAttribute(this: Printer, node: t.JSXAttribute) {\n this.print(node.name);\n if (node.value) {\n this.token(\"=\");\n this.print(node.value);\n }\n}\n\nexport function JSXIdentifier(this: Printer, node: t.JSXIdentifier) {\n this.word(node.name);\n}\n\nexport function JSXNamespacedName(this: Printer, node: t.JSXNamespacedName) {\n this.print(node.namespace);\n this.token(\":\");\n this.print(node.name);\n}\n\nexport function JSXMemberExpression(\n this: Printer,\n node: t.JSXMemberExpression,\n) {\n this.print(node.object);\n this.token(\".\");\n this.print(node.property);\n}\n\nexport function JSXSpreadAttribute(this: Printer, node: t.JSXSpreadAttribute) {\n this.token(\"{\");\n this.token(\"...\");\n this.print(node.argument);\n this.rightBrace(node);\n}\n\nexport function JSXExpressionContainer(\n this: Printer,\n node: t.JSXExpressionContainer,\n) {\n this.token(\"{\");\n this.print(node.expression);\n this.rightBrace(node);\n}\n\nexport function JSXSpreadChild(this: Printer, node: t.JSXSpreadChild) {\n this.token(\"{\");\n this.token(\"...\");\n this.print(node.expression);\n this.rightBrace(node);\n}\n\nexport function JSXText(this: Printer, node: t.JSXText) {\n const raw = this.getPossibleRaw(node);\n\n if (raw !== undefined) {\n this.token(raw, true);\n } else {\n this.token(node.value, true);\n }\n}\n\nexport function JSXElement(this: Printer, node: t.JSXElement) {\n const open = node.openingElement;\n this.print(open);\n if (open.selfClosing) return;\n\n this.indent();\n for (const child of node.children) {\n this.print(child);\n }\n this.dedent();\n\n this.print(node.closingElement);\n}\n\nfunction spaceSeparator(this: Printer) {\n this.space();\n}\n\nexport function JSXOpeningElement(this: Printer, node: t.JSXOpeningElement) {\n this.token(\"<\");\n this.print(node.name);\n this.print(node.typeParameters); // TS\n if (node.attributes.length > 0) {\n this.space();\n this.printJoin(node.attributes, { separator: spaceSeparator });\n }\n if (node.selfClosing) {\n this.space();\n this.token(\"/\");\n }\n this.token(\">\");\n}\n\nexport function JSXClosingElement(this: Printer, node: t.JSXClosingElement) {\n this.token(\"<\");\n this.token(\"/\");\n this.print(node.name);\n this.token(\">\");\n}\n\nexport function JSXEmptyExpression(this: Printer) {\n // This node is empty, so forcefully print its inner comments.\n this.printInnerComments();\n}\n\nexport function JSXFragment(this: Printer, node: t.JSXFragment) {\n this.print(node.openingFragment);\n\n this.indent();\n for (const child of node.children) {\n this.print(child);\n }\n this.dedent();\n\n this.print(node.closingFragment);\n}\n\nexport function JSXOpeningFragment(this: Printer) {\n this.token(\"<\");\n this.token(\">\");\n}\n\nexport function JSXClosingFragment(this: Printer) {\n this.token(\"</\");\n this.token(\">\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAGO,SAASA,YAAYA,CAAgBC,IAAoB,E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E;MAAEG,SAAS,EAAEP;IAAe,CAAC,CAAC;EAChE;EACA,IAAI/B,IAAI,CAACyB,WAAW,EAAE;IACpB,IAAI,CAACO,KAAK,CAAC,CAAC;IACZ,IAAI,CAAC5B,SAAK,GAAI,CAAC;EACjB;EACA,IAAI,CAACA,SAAK,GAAI,CAAC;AACjB;AAEO,SAASmC,iBAAiBA,CAAgBvC,IAAyB,EAAE;EAC1E,IAAI,CAACI,SAAK,GAAI,CAAC;EACf,IAAI,CAACA,SAAK,GAAI,CAAC;EACf,IAAI,CAACH,KAAK,CAACD,IAAI,CAACE,IAAI,CAAC;EACrB,IAAI,CAACE,SAAK,GAAI,CAAC;AACjB;AAEO,SAASoC,kBAAkBA,CAAA,EAAgB;EAEhD,IAAI,CAACC,kBAAkB,CAAC,CAAC;AAC3B;AAEO,SAASC,WAAWA,CAAgB1C,IAAmB,EAAE;EAC9D,IAAI,CAACC,KAAK,CAACD,IAAI,CAAC2C,eAAe,CAAC;EAEhC,IAAI,CAACjB,MAAM,CAAC,CAAC;EACb,KAAK,MAAMC,KAAK,IAAI3B,IAAI,CAAC4B,QAAQ,EAAE;IACjC,IAAI,CAAC3B,KAAK,CAAC0B,KAAK,CAAC;EACnB;EACA,IAAI,CAACE,MAAM,CAAC,CAAC;EAEb,IAAI,CAAC5B,KAAK,CAACD,IAAI,CAAC4C,eAAe,CAAC;AAClC;AAEO,SAASC,kBAAkBA,CAAA,EAAgB;EAChD,IAAI,CAACzC,SAAK,GAAI,CAAC;EACf,IAAI,CAACA,SAAK,GAAI,CAAC;AACjB;AAEO,SAAS0C,kBAAkBA,CAAA,EAAgB;EAChD,IAAI,CAAC1C,KAAK,CAAC,IAAI,CAAC;EAChB,IAAI,CAACA,SAAK,GAAI,CAAC;AACjB","ignoreList":[]}1 {"version":3,"names":["JSXAttribute","node","print","name","value","token","JSXIdentifier","word","JSXNamespacedName","namespace","JSXMemberExpression","object","property","JSXSpreadAttribute","argument","rightBrace","JSXExpressionContainer","expression","JSXSpreadChild","JSXText","raw","getPossibleRaw","undefined","JSXElement","open","openingElement","selfClosing","indent","child","children","dedent","closingElement","spaceSeparator","space","JSXOpeningElement","typeArguments","typeParameters","attributes","length","printJoin","JSXClosingElement","JSXEmptyExpression","printInnerComments","JSXFragment","openingFragment","closingFragment","JSXOpeningFragment","JSXClosingFragment"],"sources":["../../src/generators/jsx.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function JSXAttribute(this: Printer, node: t.JSXAttribute) {\n this.print(node.name);\n if (node.value) {\n this.token(\"=\");\n this.print(node.value);\n }\n}\n\nexport function JSXIdentifier(this: Printer, node: t.JSXIdentifier) {\n this.word(node.name);\n}\n\nexport function JSXNamespacedName(this: Printer, node: t.JSXNamespacedName) {\n this.print(node.namespace);\n this.token(\":\");\n this.print(node.name);\n}\n\nexport function JSXMemberExpression(\n this: Printer,\n node: t.JSXMemberExpression,\n) {\n this.print(node.object);\n this.token(\".\");\n this.print(node.property);\n}\n\nexport function JSXSpreadAttribute(this: Printer, node: t.JSXSpreadAttribute) {\n this.token(\"{\");\n this.token(\"...\");\n this.print(node.argument);\n this.rightBrace(node);\n}\n\nexport function JSXExpressionContainer(\n this: Printer,\n node: t.JSXExpressionContainer,\n) {\n this.token(\"{\");\n this.print(node.expression);\n this.rightBrace(node);\n}\n\nexport function JSXSpreadChild(this: Printer, node: t.JSXSpreadChild) {\n this.token(\"{\");\n this.token(\"...\");\n this.print(node.expression);\n this.rightBrace(node);\n}\n\nexport function JSXText(this: Printer, node: t.JSXText) {\n const raw = this.getPossibleRaw(node);\n\n if (raw !== undefined) {\n this.token(raw, true);\n } else {\n this.token(node.value, true);\n }\n}\n\nexport function JSXElement(this: Printer, node: t.JSXElement) {\n const open = node.openingElement;\n this.print(open);\n if (open.selfClosing) return;\n\n this.indent();\n for (const child of node.children) {\n this.print(child);\n }\n this.dedent();\n\n this.print(node.closingElement);\n}\n\nfunction spaceSeparator(this: Printer) {\n this.space();\n}\n\nexport function JSXOpeningElement(this: Printer, node: t.JSXOpeningElement) {\n this.token(\"<\");\n this.print(node.name);\n if (process.env.BABEL_8_BREAKING) {\n //@ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n this.print(node.typeArguments);\n } else {\n if (node.typeArguments) {\n this.print(node.typeArguments); // Flow AST\n }\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n this.print(node.typeParameters); // Legacy TS AST\n }\n\n if (node.attributes.length > 0) {\n this.space();\n this.printJoin(node.attributes, undefined, undefined, spaceSeparator);\n }\n if (node.selfClosing) {\n this.space();\n this.token(\"/\");\n }\n this.token(\">\");\n}\n\nexport function JSXClosingElement(this: Printer, node: t.JSXClosingElement) {\n this.token(\"<\");\n this.token(\"/\");\n this.print(node.name);\n this.token(\">\");\n}\n\nexport function JSXEmptyExpression(this: Printer) {\n // This node is empty, so forcefully print its inner comments.\n this.printInnerComments();\n}\n\nexport function JSXFragment(this: Printer, node: t.JSXFragment) {\n this.print(node.openingFragment);\n\n this.indent();\n for (const child of node.children) {\n this.print(child);\n }\n this.dedent();\n\n this.print(node.closingFragment);\n}\n\nexport function JSXOpeningFragment(this: Printer) {\n this.token(\"<\");\n this.token(\">\");\n}\n\nexport function JSXClosingFragment(this: Printer) {\n this.token(\"</\");\n this.token(\">\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAGO,SAASA,YAAYA,CAAgBC,IAAoB,EAAE;EAChE,IAAI,CAACC,KAAK,CAACD,IAAI,CAACE,IAAI,CAAC;EACrB,IAAIF,IAAI,CAACG,KAAK,EAAE;IACd,IAAI,CAACC,SAAK,GAAI,CAAC;IACf,IAAI,CAACH,KAAK,CAACD,IAAI,CAACG,KAAK,CAAC;EACxB;AACF;AAEO,SAASE,aAAaA,CAAgBL,IAAqB,EAAE;EAClE,IAAI,CAACM,IAAI,CAACN,IAAI,CAACE,IAAI,CAAC;AACtB;AAEO,SAASK,iBAAiBA,CAAgBP,IAAyB,EAAE;EAC1E,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C,IAAyB,EAAE;EAC1E,IAAI,CAACI,SAAK,GAAI,CAAC;EACf,IAAI,CAACA,SAAK,GAAI,CAAC;EACf,IAAI,CAACH,KAAK,CAACD,IAAI,CAACE,IAAI,CAAC;EACrB,IAAI,CAACE,SAAK,GAAI,CAAC;AACjB;AAEO,SAASoC,kBAAkBA,CAAA,EAAgB;EAEhD,IAAI,CAACC,kBAAkB,CAAC,CAAC;AAC3B;AAEO,SAASC,WAAWA,CAAgB1C,IAAmB,EAAE;EAC9D,IAAI,CAACC,KAAK,CAACD,IAAI,CAAC2C,eAAe,CAAC;EAEhC,IAAI,CAACjB,MAAM,CAAC,CAAC;EACb,KAAK,MAAMC,KAAK,IAAI3B,IAAI,CAAC4B,QAAQ,EAAE;IACjC,IAAI,CAAC3B,KAAK,CAAC0B,KAAK,CAAC;EACnB;EACA,IAAI,CAACE,MAAM,CAAC,CAAC;EAEb,IAAI,CAAC5B,KAAK,CAACD,IAAI,CAAC4C,eAAe,CAAC;AAClC;AAEO,SAASC,kBAAkBA,CAAA,EAAgB;EAChD,IAAI,CAACzC,SAAK,GAAI,CAAC;EACf,IAAI,CAACA,SAAK,GAAI,CAAC;AACjB;AAEO,SAAS0C,kBAAkBA,CAAA,EAAgB;EAChD,IAAI,CAAC1C,KAAK,CAAC,IAAI,CAAC;EAChB,IAAI,CAACA,SAAK,GAAI,CAAC;AACjB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/modules.js
r0c6b92a r79a0317 95 95 this.token("{", null, occurrenceCount); 96 96 this.space(); 97 this.printList(attributes || assertions, { 98 printTrailingSeparator: this.shouldPrintTrailingComma("}") 99 }); 97 this.printList(attributes || assertions, this.shouldPrintTrailingComma("}")); 100 98 this.space(); 101 99 this.token("}", null, occurrenceCount); … … 161 159 if (specifiers.length) { 162 160 this.space(); 163 this.printList(specifiers, { 164 printTrailingSeparator: this.shouldPrintTrailingComma("}") 165 }); 161 this.printList(specifiers, this.shouldPrintTrailingComma("}")); 166 162 this.space(); 167 163 } … … 233 229 this.tokenChar(123); 234 230 this.space(); 235 this.printList(specifiers, { 236 printTrailingSeparator: this.shouldPrintTrailingComma("}") 237 }); 231 this.printList(specifiers, this.shouldPrintTrailingComma("}")); 238 232 this.space(); 239 233 this.tokenChar(125); -
imaps-frontend/node_modules/@babel/generator/lib/generators/modules.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_index","isClassDeclaration","isExportDefaultSpecifier","isExportNamespaceSpecifier","isImportDefaultSpecifier","isImportNamespaceSpecifier","isStatement","ImportSpecifier","node","importKind","word","space","print","imported","local","name","ImportDefaultSpecifier","ExportDefaultSpecifier","exported","ExportSpecifier","exportKind","ExportNamespaceSpecifier","token","warningShown","_printAttributes","hasPreviousBrace","importAttributesKeyword","format","attributes","assertions","console","warn","useAssertKeyword","printList","occurrenceCount"," printTrailingSeparator","shouldPrintTrailingComma","ExportAllDeclaration","_node$attributes","_node$assertions","length","source","semicolon","maybePrintDecoratorsBeforeExport","printer","declaration","_shouldPrintDecoratorsBeforeExport","printJoin","decorators","ExportNamedDeclaration","declar","specifiers","slice","hasSpecial","first","shift","hasBrace","_node$attributes2","_node$assertions2","ExportDefaultDeclaration","noIndentInnerCommentsHere","tokenContext","TokenContext","exportDefault","ImportDeclaration","_node$attributes3","_node$assertions3","isTypeKind","module","phase","hasSpecifiers","ImportAttribute","key","value","ImportNamespaceSpecifier","ImportExpression","options"],"sources":["../../src/generators/modules.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isClassDeclaration,\n isExportDefaultSpecifier,\n isExportNamespaceSpecifier,\n isImportDefaultSpecifier,\n isImportNamespaceSpecifier,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function ImportSpecifier(this: Printer, node: t.ImportSpecifier) {\n if (node.importKind === \"type\" || node.importKind === \"typeof\") {\n this.word(node.importKind);\n this.space();\n }\n\n this.print(node.imported);\n // @ts-expect-error todo(flow-ts) maybe check node type instead of relying on name to be undefined on t.StringLiteral\n if (node.local && node.local.name !== node.imported.name) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.local);\n }\n}\n\nexport function ImportDefaultSpecifier(\n this: Printer,\n node: t.ImportDefaultSpecifier,\n) {\n this.print(node.local);\n}\n\nexport function ExportDefaultSpecifier(\n this: Printer,\n node: t.ExportDefaultSpecifier,\n) {\n this.print(node.exported);\n}\n\nexport function ExportSpecifier(this: Printer, node: t.ExportSpecifier) {\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n\n this.print(node.local);\n // @ts-expect-error todo(flow-ts) maybe check node type instead of relying on name to be undefined on t.StringLiteral\n if (node.exported && node.local.name !== node.exported.name) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.exported);\n }\n}\n\nexport function ExportNamespaceSpecifier(\n this: Printer,\n node: t.ExportNamespaceSpecifier,\n) {\n this.token(\"*\");\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.exported);\n}\n\nlet warningShown = false;\n\nexport function _printAttributes(\n this: Printer,\n node: Extract<t.Node, { attributes?: t.ImportAttribute[] }>,\n hasPreviousBrace: boolean,\n) {\n const { importAttributesKeyword } = this.format;\n const { attributes, assertions } = node;\n\n if (\n !process.env.BABEL_8_BREAKING &&\n attributes &&\n !importAttributesKeyword &&\n // In the production build only show the warning once.\n // We want to show it per-usage locally for tests.\n (!process.env.IS_PUBLISH || !warningShown)\n ) {\n warningShown = true;\n console.warn(`\\\nYou are using import attributes, without specifying the desired output syntax.\nPlease specify the \"importAttributesKeyword\" generator option, whose value can be one of:\n - \"with\" : \\`import { a } from \"b\" with { type: \"json\" };\\`\n - \"assert\" : \\`import { a } from \"b\" assert { type: \"json\" };\\`\n - \"with-legacy\" : \\`import { a } from \"b\" with type: \"json\";\\`\n`);\n }\n\n const useAssertKeyword =\n importAttributesKeyword === \"assert\" ||\n (!importAttributesKeyword && assertions);\n\n this.word(useAssertKeyword ? \"assert\" : \"with\");\n this.space();\n\n if (\n !process.env.BABEL_8_BREAKING &&\n !useAssertKeyword &&\n importAttributesKeyword !== \"with\"\n ) {\n // with-legacy\n this.printList(attributes || assertions);\n return;\n }\n\n const occurrenceCount = hasPreviousBrace ? 1 : 0;\n\n this.token(\"{\", null, occurrenceCount);\n this.space();\n this.printList(attributes || assertions, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\"}\"),\n });\n this.space();\n this.token(\"}\", null, occurrenceCount);\n}\n\nexport function ExportAllDeclaration(\n this: Printer,\n node: t.ExportAllDeclaration | t.DeclareExportAllDeclaration,\n) {\n this.word(\"export\");\n this.space();\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n this.token(\"*\");\n this.space();\n this.word(\"from\");\n this.space();\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, false);\n } else {\n this.print(node.source);\n }\n\n this.semicolon();\n}\n\nfunction maybePrintDecoratorsBeforeExport(\n printer: Printer,\n node: t.ExportNamedDeclaration | t.ExportDefaultDeclaration,\n) {\n if (\n isClassDeclaration(node.declaration) &&\n printer._shouldPrintDecoratorsBeforeExport(\n node as t.ExportNamedDeclaration & { declaration: t.ClassDeclaration },\n )\n ) {\n printer.printJoin(node.declaration.decorators);\n }\n}\n\nexport function ExportNamedDeclaration(\n this: Printer,\n node: t.ExportNamedDeclaration,\n) {\n maybePrintDecoratorsBeforeExport(this, node);\n\n this.word(\"export\");\n this.space();\n if (node.declaration) {\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n } else {\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n\n const specifiers = node.specifiers.slice(0);\n\n // print \"special\" specifiers first\n let hasSpecial = false;\n for (;;) {\n const first = specifiers[0];\n if (\n isExportDefaultSpecifier(first) ||\n isExportNamespaceSpecifier(first)\n ) {\n hasSpecial = true;\n this.print(specifiers.shift());\n if (specifiers.length) {\n this.token(\",\");\n this.space();\n }\n } else {\n break;\n }\n }\n\n let hasBrace = false;\n if (specifiers.length || (!specifiers.length && !hasSpecial)) {\n hasBrace = true;\n this.token(\"{\");\n if (specifiers.length) {\n this.space();\n this.printList(specifiers, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\"}\"),\n });\n this.space();\n }\n this.token(\"}\");\n }\n\n if (node.source) {\n this.space();\n this.word(\"from\");\n this.space();\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, hasBrace);\n } else {\n this.print(node.source);\n }\n }\n\n this.semicolon();\n }\n}\n\nexport function ExportDefaultDeclaration(\n this: Printer,\n node: t.ExportDefaultDeclaration,\n) {\n maybePrintDecoratorsBeforeExport(this, node);\n\n this.word(\"export\");\n this.noIndentInnerCommentsHere();\n this.space();\n this.word(\"default\");\n this.space();\n this.tokenContext |= TokenContext.exportDefault;\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n}\n\nexport function ImportDeclaration(this: Printer, node: t.ImportDeclaration) {\n this.word(\"import\");\n this.space();\n\n const isTypeKind = node.importKind === \"type\" || node.importKind === \"typeof\";\n if (isTypeKind) {\n this.noIndentInnerCommentsHere();\n this.word(node.importKind);\n this.space();\n } else if (node.module) {\n this.noIndentInnerCommentsHere();\n this.word(\"module\");\n this.space();\n } else if (node.phase) {\n this.noIndentInnerCommentsHere();\n this.word(node.phase);\n this.space();\n }\n\n const specifiers = node.specifiers.slice(0);\n const hasSpecifiers = !!specifiers.length;\n // print \"special\" specifiers first. The loop condition is constant,\n // but there is a \"break\" in the body.\n while (hasSpecifiers) {\n const first = specifiers[0];\n if (isImportDefaultSpecifier(first) || isImportNamespaceSpecifier(first)) {\n this.print(specifiers.shift());\n if (specifiers.length) {\n this.token(\",\");\n this.space();\n }\n } else {\n break;\n }\n }\n\n let hasBrace = false;\n if (specifiers.length) {\n hasBrace = true;\n this.token(\"{\");\n this.space();\n this.printList(specifiers, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\"}\"),\n });\n this.space();\n this.token(\"}\");\n } else if (isTypeKind && !hasSpecifiers) {\n hasBrace = true;\n this.token(\"{\");\n this.token(\"}\");\n }\n\n if (hasSpecifiers || isTypeKind) {\n this.space();\n this.word(\"from\");\n this.space();\n }\n\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, hasBrace);\n } else {\n this.print(node.source);\n }\n\n this.semicolon();\n}\n\nexport function ImportAttribute(this: Printer, node: t.ImportAttribute) {\n this.print(node.key);\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ImportNamespaceSpecifier(\n this: Printer,\n node: t.ImportNamespaceSpecifier,\n) {\n this.token(\"*\");\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.local);\n}\n\nexport function ImportExpression(this: Printer, node: t.ImportExpression) {\n this.word(\"import\");\n if (node.phase) {\n this.token(\".\");\n this.word(node.phase);\n }\n this.token(\"(\");\n this.print(node.source);\n if (node.options != null) {\n this.token(\",\");\n this.space();\n this.print(node.options);\n }\n this.token(\")\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AASA,IAAAC,MAAA,GAAAD,OAAA;AAAgD;EAR9CE,kBAAkB;EAClBC,wBAAwB;EACxBC,0BAA0B;EAC1BC,wBAAwB;EACxBC,0BAA0B;EAC1BC;AAAW,IAAAR,EAAA;AAKN,SAASS,eAAeA,CAAgBC,IAAuB,EAAE;EACtE,IAAIA,IAAI,CAACC,UAAU,KAAK,MAAM,IAAID,IAAI,CAACC,UAAU,KAAK,QAAQ,EAAE;IAC9D,IAAI,CAACC,IAAI,CAACF,IAAI,CAACC,UAAU,CAAC;IAC1B,IAAI,CAACE,KAAK,CAAC,CAAC;EACd;EAEA,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACK,QAAQ,CAAC;EAEzB,IAAIL,IAAI,CAACM,KAAK,IAAIN,IAAI,CAACM,KAAK,CAACC,IA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CAAgB/D,IAAuB,EAAE;EACtE,IAAI,CAACI,KAAK,CAACJ,IAAI,CAACgE,GAAG,CAAC;EACpB,IAAI,CAAClD,SAAK,GAAI,CAAC;EACf,IAAI,CAACX,KAAK,CAAC,CAAC;EACZ,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACiE,KAAK,CAAC;AACxB;AAEO,SAASC,wBAAwBA,CAEtClE,IAAgC,EAChC;EACA,IAAI,CAACc,SAAK,GAAI,CAAC;EACf,IAAI,CAACX,KAAK,CAAC,CAAC;EACZ,IAAI,CAACD,IAAI,CAAC,IAAI,CAAC;EACf,IAAI,CAACC,KAAK,CAAC,CAAC;EACZ,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACM,KAAK,CAAC;AACxB;AAEO,SAAS6D,gBAAgBA,CAAgBnE,IAAwB,EAAE;EACxE,IAAI,CAACE,IAAI,CAAC,QAAQ,CAAC;EACnB,IAAIF,IAAI,CAAC6D,KAAK,EAAE;IACd,IAAI,CAAC/C,SAAK,GAAI,CAAC;IACf,IAAI,CAACZ,IAAI,CAACF,IAAI,CAAC6D,KAAK,CAAC;EACvB;EACA,IAAI,CAAC/C,SAAK,GAAI,CAAC;EACf,IAAI,CAACV,KAAK,CAACJ,IAAI,CAACiC,MAAM,CAAC;EACvB,IAAIjC,IAAI,CAACoE,OAAO,IAAI,IAAI,EAAE;IACxB,IAAI,CAACtD,SAAK,GAAI,CAAC;IACf,IAAI,CAACX,KAAK,CAAC,CAAC;IACZ,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACoE,OAAO,CAAC;EAC1B;EACA,IAAI,CAACtD,SAAK,GAAI,CAAC;AACjB","ignoreList":[]}1 {"version":3,"names":["_t","require","_index","isClassDeclaration","isExportDefaultSpecifier","isExportNamespaceSpecifier","isImportDefaultSpecifier","isImportNamespaceSpecifier","isStatement","ImportSpecifier","node","importKind","word","space","print","imported","local","name","ImportDefaultSpecifier","ExportDefaultSpecifier","exported","ExportSpecifier","exportKind","ExportNamespaceSpecifier","token","warningShown","_printAttributes","hasPreviousBrace","importAttributesKeyword","format","attributes","assertions","console","warn","useAssertKeyword","printList","occurrenceCount","shouldPrintTrailingComma","ExportAllDeclaration","_node$attributes","_node$assertions","length","source","semicolon","maybePrintDecoratorsBeforeExport","printer","declaration","_shouldPrintDecoratorsBeforeExport","printJoin","decorators","ExportNamedDeclaration","declar","specifiers","slice","hasSpecial","first","shift","hasBrace","_node$attributes2","_node$assertions2","ExportDefaultDeclaration","noIndentInnerCommentsHere","tokenContext","TokenContext","exportDefault","ImportDeclaration","_node$attributes3","_node$assertions3","isTypeKind","module","phase","hasSpecifiers","ImportAttribute","key","value","ImportNamespaceSpecifier","ImportExpression","options"],"sources":["../../src/generators/modules.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isClassDeclaration,\n isExportDefaultSpecifier,\n isExportNamespaceSpecifier,\n isImportDefaultSpecifier,\n isImportNamespaceSpecifier,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function ImportSpecifier(this: Printer, node: t.ImportSpecifier) {\n if (node.importKind === \"type\" || node.importKind === \"typeof\") {\n this.word(node.importKind);\n this.space();\n }\n\n this.print(node.imported);\n // @ts-expect-error todo(flow-ts) maybe check node type instead of relying on name to be undefined on t.StringLiteral\n if (node.local && node.local.name !== node.imported.name) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.local);\n }\n}\n\nexport function ImportDefaultSpecifier(\n this: Printer,\n node: t.ImportDefaultSpecifier,\n) {\n this.print(node.local);\n}\n\nexport function ExportDefaultSpecifier(\n this: Printer,\n node: t.ExportDefaultSpecifier,\n) {\n this.print(node.exported);\n}\n\nexport function ExportSpecifier(this: Printer, node: t.ExportSpecifier) {\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n\n this.print(node.local);\n // @ts-expect-error todo(flow-ts) maybe check node type instead of relying on name to be undefined on t.StringLiteral\n if (node.exported && node.local.name !== node.exported.name) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.exported);\n }\n}\n\nexport function ExportNamespaceSpecifier(\n this: Printer,\n node: t.ExportNamespaceSpecifier,\n) {\n this.token(\"*\");\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.exported);\n}\n\nlet warningShown = false;\n\nexport function _printAttributes(\n this: Printer,\n node: Extract<t.Node, { attributes?: t.ImportAttribute[] }>,\n hasPreviousBrace: boolean,\n) {\n const { importAttributesKeyword } = this.format;\n const { attributes, assertions } = node;\n\n if (\n !process.env.BABEL_8_BREAKING &&\n attributes &&\n !importAttributesKeyword &&\n // In the production build only show the warning once.\n // We want to show it per-usage locally for tests.\n (!process.env.IS_PUBLISH || !warningShown)\n ) {\n warningShown = true;\n console.warn(`\\\nYou are using import attributes, without specifying the desired output syntax.\nPlease specify the \"importAttributesKeyword\" generator option, whose value can be one of:\n - \"with\" : \\`import { a } from \"b\" with { type: \"json\" };\\`\n - \"assert\" : \\`import { a } from \"b\" assert { type: \"json\" };\\`\n - \"with-legacy\" : \\`import { a } from \"b\" with type: \"json\";\\`\n`);\n }\n\n const useAssertKeyword =\n importAttributesKeyword === \"assert\" ||\n (!importAttributesKeyword && assertions);\n\n this.word(useAssertKeyword ? \"assert\" : \"with\");\n this.space();\n\n if (\n !process.env.BABEL_8_BREAKING &&\n !useAssertKeyword &&\n importAttributesKeyword !== \"with\"\n ) {\n // with-legacy\n this.printList(attributes || assertions);\n return;\n }\n\n const occurrenceCount = hasPreviousBrace ? 1 : 0;\n\n this.token(\"{\", null, occurrenceCount);\n this.space();\n this.printList(attributes || assertions, this.shouldPrintTrailingComma(\"}\"));\n this.space();\n this.token(\"}\", null, occurrenceCount);\n}\n\nexport function ExportAllDeclaration(\n this: Printer,\n node: t.ExportAllDeclaration | t.DeclareExportAllDeclaration,\n) {\n this.word(\"export\");\n this.space();\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n this.token(\"*\");\n this.space();\n this.word(\"from\");\n this.space();\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, false);\n } else {\n this.print(node.source);\n }\n\n this.semicolon();\n}\n\nfunction maybePrintDecoratorsBeforeExport(\n printer: Printer,\n node: t.ExportNamedDeclaration | t.ExportDefaultDeclaration,\n) {\n if (\n isClassDeclaration(node.declaration) &&\n printer._shouldPrintDecoratorsBeforeExport(\n node as t.ExportNamedDeclaration & { declaration: t.ClassDeclaration },\n )\n ) {\n printer.printJoin(node.declaration.decorators);\n }\n}\n\nexport function ExportNamedDeclaration(\n this: Printer,\n node: t.ExportNamedDeclaration,\n) {\n maybePrintDecoratorsBeforeExport(this, node);\n\n this.word(\"export\");\n this.space();\n if (node.declaration) {\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n } else {\n if (node.exportKind === \"type\") {\n this.word(\"type\");\n this.space();\n }\n\n const specifiers = node.specifiers.slice(0);\n\n // print \"special\" specifiers first\n let hasSpecial = false;\n for (;;) {\n const first = specifiers[0];\n if (\n isExportDefaultSpecifier(first) ||\n isExportNamespaceSpecifier(first)\n ) {\n hasSpecial = true;\n this.print(specifiers.shift());\n if (specifiers.length) {\n this.token(\",\");\n this.space();\n }\n } else {\n break;\n }\n }\n\n let hasBrace = false;\n if (specifiers.length || (!specifiers.length && !hasSpecial)) {\n hasBrace = true;\n this.token(\"{\");\n if (specifiers.length) {\n this.space();\n this.printList(specifiers, this.shouldPrintTrailingComma(\"}\"));\n this.space();\n }\n this.token(\"}\");\n }\n\n if (node.source) {\n this.space();\n this.word(\"from\");\n this.space();\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, hasBrace);\n } else {\n this.print(node.source);\n }\n }\n\n this.semicolon();\n }\n}\n\nexport function ExportDefaultDeclaration(\n this: Printer,\n node: t.ExportDefaultDeclaration,\n) {\n maybePrintDecoratorsBeforeExport(this, node);\n\n this.word(\"export\");\n this.noIndentInnerCommentsHere();\n this.space();\n this.word(\"default\");\n this.space();\n this.tokenContext |= TokenContext.exportDefault;\n const declar = node.declaration;\n this.print(declar);\n if (!isStatement(declar)) this.semicolon();\n}\n\nexport function ImportDeclaration(this: Printer, node: t.ImportDeclaration) {\n this.word(\"import\");\n this.space();\n\n const isTypeKind = node.importKind === \"type\" || node.importKind === \"typeof\";\n if (isTypeKind) {\n this.noIndentInnerCommentsHere();\n this.word(node.importKind);\n this.space();\n } else if (node.module) {\n this.noIndentInnerCommentsHere();\n this.word(\"module\");\n this.space();\n } else if (node.phase) {\n this.noIndentInnerCommentsHere();\n this.word(node.phase);\n this.space();\n }\n\n const specifiers = node.specifiers.slice(0);\n const hasSpecifiers = !!specifiers.length;\n // print \"special\" specifiers first. The loop condition is constant,\n // but there is a \"break\" in the body.\n while (hasSpecifiers) {\n const first = specifiers[0];\n if (isImportDefaultSpecifier(first) || isImportNamespaceSpecifier(first)) {\n this.print(specifiers.shift());\n if (specifiers.length) {\n this.token(\",\");\n this.space();\n }\n } else {\n break;\n }\n }\n\n let hasBrace = false;\n if (specifiers.length) {\n hasBrace = true;\n this.token(\"{\");\n this.space();\n this.printList(specifiers, this.shouldPrintTrailingComma(\"}\"));\n this.space();\n this.token(\"}\");\n } else if (isTypeKind && !hasSpecifiers) {\n hasBrace = true;\n this.token(\"{\");\n this.token(\"}\");\n }\n\n if (hasSpecifiers || isTypeKind) {\n this.space();\n this.word(\"from\");\n this.space();\n }\n\n if (node.attributes?.length || node.assertions?.length) {\n this.print(node.source, true);\n this.space();\n this._printAttributes(node, hasBrace);\n } else {\n this.print(node.source);\n }\n\n this.semicolon();\n}\n\nexport function ImportAttribute(this: Printer, node: t.ImportAttribute) {\n this.print(node.key);\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ImportNamespaceSpecifier(\n this: Printer,\n node: t.ImportNamespaceSpecifier,\n) {\n this.token(\"*\");\n this.space();\n this.word(\"as\");\n this.space();\n this.print(node.local);\n}\n\nexport function ImportExpression(this: Printer, node: t.ImportExpression) {\n this.word(\"import\");\n if (node.phase) {\n this.token(\".\");\n this.word(node.phase);\n }\n this.token(\"(\");\n this.print(node.source);\n if (node.options != null) {\n this.token(\",\");\n this.space();\n this.print(node.options);\n }\n this.token(\")\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AASA,IAAAC,MAAA,GAAAD,OAAA;AAAgD;EAR9CE,kBAAkB;EAClBC,wBAAwB;EACxBC,0BAA0B;EAC1BC,wBAAwB;EACxBC,0BAA0B;EAC1BC;AAAW,IAAAR,EAAA;AAKN,SAASS,eAAeA,CAAgBC,IAAuB,EAAE;EACtE,IAAIA,IAAI,CAACC,UAAU,KAAK,MAAM,IAAID,IAAI,CAACC,UAAU,KAAK,QAAQ,EAAE;IAC9D,IAAI,CAACC,IAAI,CAACF,IAAI,CAACC,UAAU,CAAC;IAC1B,IAAI,CAACE,KAAK,CAAC,CAAC;EACd;EAEA,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACK,QAAQ,CAAC;EAEzB,IAAIL,IAAI,CAACM,KAAK,IAAIN,IAAI,CAACM,KAAK,CAACC,IAAI,KAAKP,IAAI,CAACK,QAAQ,CAACE,IAAI,EAAE;IACxD,IAAI,CAACJ,KAAK,CAAC,CAAC;IACZ,IAAI,CAACD,IAAI,CAAC,IAAI,CAAC;IACf,IAAI,CAACC,KAAK,CAAC,CAAC;IACZ,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACM,KAAK,CAAC;EACxB;AACF;AAEO,SAASE,sBAAsBA,CAEpCR,IAA8B,EAC9B;EACA,IAAI,CAACI,KAAK,CAACJ,IAAI,CAACM,KAAK,CAAC;AACxB;AAEO,SAASG,sBAAsBA,CAEpCT,IAA8B,EAC9B;EACA,IAAI,CAACI,KAAK,CAACJ,IAAI,CAACU,QAAQ,CAAC;AAC3B;AAEO,SAASC,eAAeA,CAAgBX,IAAuB,EAAE;EACtE,IAAIA,IAAI,CAAC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EAAE;IACd,IAAI,CAAC9C,SAAK,GAAI,CAAC;IACf,IAAI,CAACZ,IAAI,CAACF,IAAI,CAAC4D,KAAK,CAAC;EACvB;EACA,IAAI,CAAC9C,SAAK,GAAI,CAAC;EACf,IAAI,CAACV,KAAK,CAACJ,IAAI,CAACgC,MAAM,CAAC;EACvB,IAAIhC,IAAI,CAACmE,OAAO,IAAI,IAAI,EAAE;IACxB,IAAI,CAACrD,SAAK,GAAI,CAAC;IACf,IAAI,CAACX,KAAK,CAAC,CAAC;IACZ,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACmE,OAAO,CAAC;EAC1B;EACA,IAAI,CAACrD,SAAK,GAAI,CAAC;AACjB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/statements.js
r0c6b92a r79a0317 207 207 this.space(); 208 208 this.tokenChar(123); 209 this.printSequence(node.cases, { 210 indent: true, 211 addNewlines(leading, cas) { 212 if (!leading && node.cases[node.cases.length - 1] === cas) return -1; 213 } 209 this.printSequence(node.cases, true, undefined, function addNewlines(leading, cas) { 210 if (!leading && node.cases[node.cases.length - 1] === cas) return -1; 214 211 }); 215 212 this.rightBrace(node); … … 227 224 if (node.consequent.length) { 228 225 this.newline(); 229 this.printSequence(node.consequent, { 230 indent: true 231 }); 226 this.printSequence(node.consequent, true); 232 227 } 233 228 } … … 260 255 } 261 256 } 262 this.printList(node.declarations, { 263 separator: hasInits ? function (occurrenceCount) { 264 this.token(",", false, occurrenceCount); 265 this.newline(); 266 } : undefined, 267 indent: node.declarations.length > 1 ? true : false 268 }); 257 this.printList(node.declarations, undefined, undefined, node.declarations.length > 1, hasInits ? function (occurrenceCount) { 258 this.token(",", false, occurrenceCount); 259 this.newline(); 260 } : undefined); 269 261 if (isFor(parent)) { 270 262 if (isForStatement(parent)) { -
imaps-frontend/node_modules/@babel/generator/lib/generators/statements.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_index","isFor","isForStatement","isIfStatement","isStatement","WithStatement","node","word","space","token","print","object","printBlock","IfStatement","test","needsBlock","alternate","getLastStatement","consequent","newline","indent","printAndIndentOnComments","dedent","endsWith","statement","body","ForStatement","exit","enterForStatementInit","tokenContext","TokenContext","forHead","init","update","WhileStatement","ForXStatement","isForOf","type","await","noIndentInnerCommentsHere","forOfHead","forInHead","left","right","ForInStatement","exports","ForOfStatement","DoWhileStatement","semicolon","printStatementAfterKeyword","printer","printTerminatorless","BreakStatement","label","ContinueStatement","ReturnStatement","argument","ThrowStatement","LabeledStatement","TryStatement","block","handlers","handler","finalizer","CatchClause","param","typeAnnotation","SwitchStatement","discriminant","printSequence","cases"," addNewlines","leading","cas","length","rightBrace","SwitchCase","DebuggerStatement","VariableDeclaration","parent","declare","kind","hasInits","declar","declarations","printList","separator","occurrenceCount","undefined","VariableDeclarator","id","definite"],"sources":["../../src/generators/statements.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isFor,\n isForStatement,\n isIfStatement,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function WithStatement(this: Printer, node: t.WithStatement) {\n this.word(\"with\");\n this.space();\n this.token(\"(\");\n this.print(node.object);\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport function IfStatement(this: Printer, node: t.IfStatement) {\n this.word(\"if\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.space();\n\n const needsBlock =\n node.alternate && isIfStatement(getLastStatement(node.consequent));\n if (needsBlock) {\n this.token(\"{\");\n this.newline();\n this.indent();\n }\n\n this.printAndIndentOnComments(node.consequent);\n\n if (needsBlock) {\n this.dedent();\n this.newline();\n this.token(\"}\");\n }\n\n if (node.alternate) {\n if (this.endsWith(charCodes.rightCurlyBrace)) this.space();\n this.word(\"else\");\n this.space();\n this.printAndIndentOnComments(node.alternate);\n }\n}\n\n// Recursively get the last statement.\nfunction getLastStatement(statement: t.Statement): t.Statement {\n // @ts-expect-error: If statement.body is empty or not a Node, isStatement will return false\n const { body } = statement;\n if (isStatement(body) === false) {\n return statement;\n }\n\n return getLastStatement(body);\n}\n\nexport function ForStatement(this: Printer, node: t.ForStatement) {\n this.word(\"for\");\n this.space();\n this.token(\"(\");\n\n {\n const exit = this.enterForStatementInit();\n this.tokenContext |= TokenContext.forHead;\n this.print(node.init);\n exit();\n }\n\n this.token(\";\");\n\n if (node.test) {\n this.space();\n this.print(node.test);\n }\n this.token(\";\", false, 1);\n\n if (node.update) {\n this.space();\n this.print(node.update);\n }\n\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport function WhileStatement(this: Printer, node: t.WhileStatement) {\n this.word(\"while\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.printBlock(node);\n}\n\nfunction ForXStatement(this: Printer, node: t.ForXStatement) {\n this.word(\"for\");\n this.space();\n const isForOf = node.type === \"ForOfStatement\";\n if (isForOf && node.await) {\n this.word(\"await\");\n this.space();\n }\n this.noIndentInnerCommentsHere();\n this.token(\"(\");\n {\n const exit = isForOf ? null : this.enterForStatementInit();\n this.tokenContext |= isForOf\n ? TokenContext.forOfHead\n : TokenContext.forInHead;\n this.print(node.left);\n exit?.();\n }\n this.space();\n this.word(isForOf ? \"of\" : \"in\");\n this.space();\n this.print(node.right);\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport const ForInStatement = ForXStatement;\nexport const ForOfStatement = ForXStatement;\n\nexport function DoWhileStatement(this: Printer, node: t.DoWhileStatement) {\n this.word(\"do\");\n this.space();\n this.print(node.body);\n this.space();\n this.word(\"while\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.semicolon();\n}\n\nfunction printStatementAfterKeyword(printer: Printer, node: t.Node) {\n if (node) {\n printer.space();\n printer.printTerminatorless(node);\n }\n\n printer.semicolon();\n}\n\nexport function BreakStatement(this: Printer, node: t.ContinueStatement) {\n this.word(\"break\");\n printStatementAfterKeyword(this, node.label);\n}\n\nexport function ContinueStatement(this: Printer, node: t.ContinueStatement) {\n this.word(\"continue\");\n printStatementAfterKeyword(this, node.label);\n}\n\nexport function ReturnStatement(this: Printer, node: t.ReturnStatement) {\n this.word(\"return\");\n printStatementAfterKeyword(this, node.argument);\n}\n\nexport function ThrowStatement(this: Printer, node: t.ThrowStatement) {\n this.word(\"throw\");\n printStatementAfterKeyword(this, node.argument);\n}\n\nexport function LabeledStatement(this: Printer, node: t.LabeledStatement) {\n this.print(node.label);\n this.token(\":\");\n this.space();\n this.print(node.body);\n}\n\nexport function TryStatement(this: Printer, node: t.TryStatement) {\n this.word(\"try\");\n this.space();\n this.print(node.block);\n this.space();\n\n // Esprima bug puts the catch clause in a `handlers` array.\n // see https://code.google.com/p/esprima/issues/detail?id=433\n // We run into this from regenerator generated ast.\n // @ts-expect-error todo(flow->ts) should ast node type be updated to support this?\n if (node.handlers) {\n // @ts-expect-error todo(flow->ts) should ast node type be updated to support this?\n this.print(node.handlers[0]);\n } else {\n this.print(node.handler);\n }\n\n if (node.finalizer) {\n this.space();\n this.word(\"finally\");\n this.space();\n this.print(node.finalizer);\n }\n}\n\nexport function CatchClause(this: Printer, node: t.CatchClause) {\n this.word(\"catch\");\n this.space();\n if (node.param) {\n this.token(\"(\");\n this.print(node.param);\n this.print(node.param.typeAnnotation);\n this.token(\")\");\n this.space();\n }\n this.print(node.body);\n}\n\nexport function SwitchStatement(this: Printer, node: t.SwitchStatement) {\n this.word(\"switch\");\n this.space();\n this.token(\"(\");\n this.print(node.discriminant);\n this.token(\")\");\n this.space();\n this.token(\"{\");\n\n this.printSequence(node.cases, {\n indent: true,\n addNewlines(leading, cas) {\n if (!leading && node.cases[node.cases.length - 1] === cas) return -1;\n },\n });\n\n this.rightBrace(node);\n}\n\nexport function SwitchCase(this: Printer, node: t.SwitchCase) {\n if (node.test) {\n this.word(\"case\");\n this.space();\n this.print(node.test);\n this.token(\":\");\n } else {\n this.word(\"default\");\n this.token(\":\");\n }\n\n if (node.consequent.length) {\n this.newline();\n this.printSequence(node.consequent, { indent: true });\n }\n}\n\nexport function DebuggerStatement(this: Printer) {\n this.word(\"debugger\");\n this.semicolon();\n}\n\nexport function VariableDeclaration(\n this: Printer,\n node: t.VariableDeclaration,\n parent: t.Node,\n) {\n if (node.declare) {\n // TS\n this.word(\"declare\");\n this.space();\n }\n\n const { kind } = node;\n if (kind === \"await using\") {\n this.word(\"await\");\n this.space();\n this.word(\"using\", true);\n } else {\n this.word(kind, kind === \"using\");\n }\n this.space();\n\n let hasInits = false;\n // don't add whitespace to loop heads\n if (!isFor(parent)) {\n for (const declar of node.declarations) {\n if (declar.init) {\n // has an init so let's split it up over multiple lines\n hasInits = true;\n }\n }\n }\n\n //\n // use a pretty separator when we aren't in compact mode, have initializers and don't have retainLines on\n // this will format declarations like:\n //\n // let foo = \"bar\", bar = \"foo\";\n //\n // into\n //\n // let foo = \"bar\",\n // bar = \"foo\";\n //\n\n this.printList(node.declarations, {\n separator: hasInits\n ? function (this: Printer, occurrenceCount: number) {\n this.token(\",\", false, occurrenceCount);\n this.newline();\n }\n : undefined,\n indent: node.declarations.length > 1 ? true : false,\n });\n\n if (isFor(parent)) {\n // don't give semicolons to these nodes since they'll be inserted in the parent generator\n if (isForStatement(parent)) {\n if (parent.init === node) return;\n } else {\n if (parent.left === node) return;\n }\n }\n\n this.semicolon();\n}\n\nexport function VariableDeclarator(this: Printer, node: t.VariableDeclarator) {\n this.print(node.id);\n if (node.definite) this.token(\"!\"); // TS\n // @ts-ignore(Babel 7 vs Babel 8) Property 'typeAnnotation' does not exist on type 'MemberExpression'.\n this.print(node.id.typeAnnotation);\n if (node.init) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.init);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAWA,IAAAC,MAAA,GAAAD,OAAA;AAAgD;EAV9CE,KAAK;EACLC,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AAE;MAChD,IAAI,CAAC9E,KAAK,CAAC,GAAG,EAAE,KAAK,EAAE8E,eAAe,CAAC;MACvC,IAAI,CAACpE,OAAO,CAAC,CAAC;IAChB,CAAC,GACDqE,SAAS;IACbpE,MAAM,EAAEd,IAAI,CAAC8E,YAAY,CAACV,MAAM,GAAG,CAAC,GAAG,IAAI,GAAG;EAChD,CAAC,CAAC;EAEF,IAAIzE,KAAK,CAAC8E,MAAM,CAAC,EAAE;IAEjB,IAAI7E,cAAc,CAAC6E,MAAM,CAAC,EAAE;MAC1B,IAAIA,MAAM,CAAC/C,IAAI,KAAK1B,IAAI,EAAE;IAC5B,CAAC,MAAM;MACL,IAAIyE,MAAM,CAACrC,IAAI,KAAKpC,IAAI,EAAE;IAC5B;EACF;EAEA,IAAI,CAAC0C,SAAS,CAAC,CAAC;AAClB;AAEO,SAASyC,kBAAkBA,CAAgBnF,IAA0B,EAAE;EAC5E,IAAI,CAACI,KAAK,CAACJ,IAAI,CAACoF,EAAE,CAAC;EACnB,IAAIpF,IAAI,CAACqF,QAAQ,EAAE,IAAI,CAAClF,SAAK,GAAI,CAAC;EAElC,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACoF,EAAE,CAACxB,cAAc,CAAC;EAClC,IAAI5D,IAAI,CAAC0B,IAAI,EAAE;IACb,IAAI,CAACxB,KAAK,CAAC,CAAC;IACZ,IAAI,CAACC,SAAK,GAAI,CAAC;IACf,IAAI,CAACD,KAAK,CAAC,CAAC;IACZ,IAAI,CAACE,KAAK,CAACJ,IAAI,CAAC0B,IAAI,CAAC;EACvB;AACF","ignoreList":[]}1 {"version":3,"names":["_t","require","_index","isFor","isForStatement","isIfStatement","isStatement","WithStatement","node","word","space","token","print","object","printBlock","IfStatement","test","needsBlock","alternate","getLastStatement","consequent","newline","indent","printAndIndentOnComments","dedent","endsWith","statement","body","ForStatement","exit","enterForStatementInit","tokenContext","TokenContext","forHead","init","update","WhileStatement","ForXStatement","isForOf","type","await","noIndentInnerCommentsHere","forOfHead","forInHead","left","right","ForInStatement","exports","ForOfStatement","DoWhileStatement","semicolon","printStatementAfterKeyword","printer","printTerminatorless","BreakStatement","label","ContinueStatement","ReturnStatement","argument","ThrowStatement","LabeledStatement","TryStatement","block","handlers","handler","finalizer","CatchClause","param","typeAnnotation","SwitchStatement","discriminant","printSequence","cases","undefined","addNewlines","leading","cas","length","rightBrace","SwitchCase","DebuggerStatement","VariableDeclaration","parent","declare","kind","hasInits","declar","declarations","printList","occurrenceCount","VariableDeclarator","id","definite"],"sources":["../../src/generators/statements.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport {\n isFor,\n isForStatement,\n isIfStatement,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\nimport { TokenContext } from \"../node/index.ts\";\n\nexport function WithStatement(this: Printer, node: t.WithStatement) {\n this.word(\"with\");\n this.space();\n this.token(\"(\");\n this.print(node.object);\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport function IfStatement(this: Printer, node: t.IfStatement) {\n this.word(\"if\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.space();\n\n const needsBlock =\n node.alternate && isIfStatement(getLastStatement(node.consequent));\n if (needsBlock) {\n this.token(\"{\");\n this.newline();\n this.indent();\n }\n\n this.printAndIndentOnComments(node.consequent);\n\n if (needsBlock) {\n this.dedent();\n this.newline();\n this.token(\"}\");\n }\n\n if (node.alternate) {\n if (this.endsWith(charCodes.rightCurlyBrace)) this.space();\n this.word(\"else\");\n this.space();\n this.printAndIndentOnComments(node.alternate);\n }\n}\n\n// Recursively get the last statement.\nfunction getLastStatement(statement: t.Statement): t.Statement {\n // @ts-expect-error: If statement.body is empty or not a Node, isStatement will return false\n const { body } = statement;\n if (isStatement(body) === false) {\n return statement;\n }\n\n return getLastStatement(body);\n}\n\nexport function ForStatement(this: Printer, node: t.ForStatement) {\n this.word(\"for\");\n this.space();\n this.token(\"(\");\n\n {\n const exit = this.enterForStatementInit();\n this.tokenContext |= TokenContext.forHead;\n this.print(node.init);\n exit();\n }\n\n this.token(\";\");\n\n if (node.test) {\n this.space();\n this.print(node.test);\n }\n this.token(\";\", false, 1);\n\n if (node.update) {\n this.space();\n this.print(node.update);\n }\n\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport function WhileStatement(this: Printer, node: t.WhileStatement) {\n this.word(\"while\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.printBlock(node);\n}\n\nfunction ForXStatement(this: Printer, node: t.ForXStatement) {\n this.word(\"for\");\n this.space();\n const isForOf = node.type === \"ForOfStatement\";\n if (isForOf && node.await) {\n this.word(\"await\");\n this.space();\n }\n this.noIndentInnerCommentsHere();\n this.token(\"(\");\n {\n const exit = isForOf ? null : this.enterForStatementInit();\n this.tokenContext |= isForOf\n ? TokenContext.forOfHead\n : TokenContext.forInHead;\n this.print(node.left);\n exit?.();\n }\n this.space();\n this.word(isForOf ? \"of\" : \"in\");\n this.space();\n this.print(node.right);\n this.token(\")\");\n this.printBlock(node);\n}\n\nexport const ForInStatement = ForXStatement;\nexport const ForOfStatement = ForXStatement;\n\nexport function DoWhileStatement(this: Printer, node: t.DoWhileStatement) {\n this.word(\"do\");\n this.space();\n this.print(node.body);\n this.space();\n this.word(\"while\");\n this.space();\n this.token(\"(\");\n this.print(node.test);\n this.token(\")\");\n this.semicolon();\n}\n\nfunction printStatementAfterKeyword(printer: Printer, node: t.Node) {\n if (node) {\n printer.space();\n printer.printTerminatorless(node);\n }\n\n printer.semicolon();\n}\n\nexport function BreakStatement(this: Printer, node: t.ContinueStatement) {\n this.word(\"break\");\n printStatementAfterKeyword(this, node.label);\n}\n\nexport function ContinueStatement(this: Printer, node: t.ContinueStatement) {\n this.word(\"continue\");\n printStatementAfterKeyword(this, node.label);\n}\n\nexport function ReturnStatement(this: Printer, node: t.ReturnStatement) {\n this.word(\"return\");\n printStatementAfterKeyword(this, node.argument);\n}\n\nexport function ThrowStatement(this: Printer, node: t.ThrowStatement) {\n this.word(\"throw\");\n printStatementAfterKeyword(this, node.argument);\n}\n\nexport function LabeledStatement(this: Printer, node: t.LabeledStatement) {\n this.print(node.label);\n this.token(\":\");\n this.space();\n this.print(node.body);\n}\n\nexport function TryStatement(this: Printer, node: t.TryStatement) {\n this.word(\"try\");\n this.space();\n this.print(node.block);\n this.space();\n\n // Esprima bug puts the catch clause in a `handlers` array.\n // see https://code.google.com/p/esprima/issues/detail?id=433\n // We run into this from regenerator generated ast.\n // @ts-expect-error todo(flow->ts) should ast node type be updated to support this?\n if (node.handlers) {\n // @ts-expect-error todo(flow->ts) should ast node type be updated to support this?\n this.print(node.handlers[0]);\n } else {\n this.print(node.handler);\n }\n\n if (node.finalizer) {\n this.space();\n this.word(\"finally\");\n this.space();\n this.print(node.finalizer);\n }\n}\n\nexport function CatchClause(this: Printer, node: t.CatchClause) {\n this.word(\"catch\");\n this.space();\n if (node.param) {\n this.token(\"(\");\n this.print(node.param);\n this.print(node.param.typeAnnotation);\n this.token(\")\");\n this.space();\n }\n this.print(node.body);\n}\n\nexport function SwitchStatement(this: Printer, node: t.SwitchStatement) {\n this.word(\"switch\");\n this.space();\n this.token(\"(\");\n this.print(node.discriminant);\n this.token(\")\");\n this.space();\n this.token(\"{\");\n\n this.printSequence(\n node.cases,\n true,\n undefined,\n function addNewlines(leading, cas) {\n if (!leading && node.cases[node.cases.length - 1] === cas) return -1;\n },\n );\n\n this.rightBrace(node);\n}\n\nexport function SwitchCase(this: Printer, node: t.SwitchCase) {\n if (node.test) {\n this.word(\"case\");\n this.space();\n this.print(node.test);\n this.token(\":\");\n } else {\n this.word(\"default\");\n this.token(\":\");\n }\n\n if (node.consequent.length) {\n this.newline();\n this.printSequence(node.consequent, true);\n }\n}\n\nexport function DebuggerStatement(this: Printer) {\n this.word(\"debugger\");\n this.semicolon();\n}\n\nexport function VariableDeclaration(\n this: Printer,\n node: t.VariableDeclaration,\n parent: t.Node,\n) {\n if (node.declare) {\n // TS\n this.word(\"declare\");\n this.space();\n }\n\n const { kind } = node;\n if (kind === \"await using\") {\n this.word(\"await\");\n this.space();\n this.word(\"using\", true);\n } else {\n this.word(kind, kind === \"using\");\n }\n this.space();\n\n let hasInits = false;\n // don't add whitespace to loop heads\n if (!isFor(parent)) {\n for (const declar of node.declarations) {\n if (declar.init) {\n // has an init so let's split it up over multiple lines\n hasInits = true;\n }\n }\n }\n\n //\n // use a pretty separator when we aren't in compact mode, have initializers and don't have retainLines on\n // this will format declarations like:\n //\n // let foo = \"bar\", bar = \"foo\";\n //\n // into\n //\n // let foo = \"bar\",\n // bar = \"foo\";\n //\n\n this.printList(\n node.declarations,\n undefined,\n undefined,\n node.declarations.length > 1,\n hasInits\n ? function (this: Printer, occurrenceCount: number) {\n this.token(\",\", false, occurrenceCount);\n this.newline();\n }\n : undefined,\n );\n\n if (isFor(parent)) {\n // don't give semicolons to these nodes since they'll be inserted in the parent generator\n if (isForStatement(parent)) {\n if (parent.init === node) return;\n } else {\n if (parent.left === node) return;\n }\n }\n\n this.semicolon();\n}\n\nexport function VariableDeclarator(this: Printer, node: t.VariableDeclarator) {\n this.print(node.id);\n if (node.definite) this.token(\"!\"); // TS\n // @ts-ignore(Babel 7 vs Babel 8) Property 'typeAnnotation' does not exist on type 'MemberExpression'.\n this.print(node.id.typeAnnotation);\n if (node.init) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.init);\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAWA,IAAAC,MAAA,GAAAD,OAAA;AAAgD;EAV9CE,KAAK;EACLC,cAAc;EACdC,aAAa;EACbC;AAAW,IAAAN,EAAA;AASN,SAASO,aAAaA,CAAgBC,IAAqB,EAAE;EAClE,IAAI,CAACC,IAAI,CAAC,MAAM,CAAC;EACjB,IAAI,CAACC,KAAK,CAAC,CAAC;EACZ,IAAI,CAACC,SA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K,CAAC+E,MAAM,CAAC,EAAE;IAEjB,IAAI9E,cAAc,CAAC8E,MAAM,CAAC,EAAE;MAC1B,IAAIA,MAAM,CAAChD,IAAI,KAAK1B,IAAI,EAAE;IAC5B,CAAC,MAAM;MACL,IAAI0E,MAAM,CAACtC,IAAI,KAAKpC,IAAI,EAAE;IAC5B;EACF;EAEA,IAAI,CAAC0C,SAAS,CAAC,CAAC;AAClB;AAEO,SAASwC,kBAAkBA,CAAgBlF,IAA0B,EAAE;EAC5E,IAAI,CAACI,KAAK,CAACJ,IAAI,CAACmF,EAAE,CAAC;EACnB,IAAInF,IAAI,CAACoF,QAAQ,EAAE,IAAI,CAACjF,SAAK,GAAI,CAAC;EAElC,IAAI,CAACC,KAAK,CAACJ,IAAI,CAACmF,EAAE,CAACvB,cAAc,CAAC;EAClC,IAAI5D,IAAI,CAAC0B,IAAI,EAAE;IACb,IAAI,CAACxB,KAAK,CAAC,CAAC;IACZ,IAAI,CAACC,SAAK,GAAI,CAAC;IACf,IAAI,CAACD,KAAK,CAAC,CAAC;IACZ,IAAI,CAACE,KAAK,CAACJ,IAAI,CAAC0B,IAAI,CAAC;EACvB;AACF","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/template-literals.js
r0c6b92a r79a0317 9 9 function TaggedTemplateExpression(node) { 10 10 this.print(node.tag); 11 this.print(node.typeParameters); 11 { 12 this.print(node.typeParameters); 13 } 12 14 this.print(node.quasi); 13 15 } -
imaps-frontend/node_modules/@babel/generator/lib/generators/template-literals.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["TaggedTemplateExpression","node","print","tag","typeParameters","quasi","TemplateElement","Error","TemplateLiteral","quasis","partRaw","i","length","value","raw","token","expressions","tokenMap","findMatching","_catchUpTo","loc","start"],"sources":["../../src/generators/template-literals.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function TaggedTemplateExpression(\n this: Printer,\n node: t.TaggedTemplateExpression,\n) {\n this.print(node.tag);\n this.print(node.typeParameters); // TS\n this.print(node.quasi);\n}\n\nexport function TemplateElement(this: Printer) {\n throw new Error(\"TemplateElement printing is handled in TemplateLiteral\");\n}\n\nexport function TemplateLiteral(this: Printer, node: t.TemplateLiteral) {\n const quasis = node.quasis;\n\n let partRaw = \"`\";\n\n for (let i = 0; i < quasis.length; i++) {\n partRaw += quasis[i].value.raw;\n\n if (i + 1 < quasis.length) {\n this.token(partRaw + \"${\", true);\n this.print(node.expressions[i]);\n partRaw = \"}\";\n\n // In Babel 7 we have indivirual tokens for ${ and }, so the automatic\n // catchup logic does not work. Manually look for those tokens.\n if (!process.env.BABEL_8_BREAKING && this.tokenMap) {\n const token = this.tokenMap.findMatching(node, \"}\", i);\n if (token) this._catchUpTo(token.loc.start);\n }\n }\n }\n\n this.token(partRaw + \"`\", true);\n}\n"],"mappings":";;;;;;;;AAGO,SAASA,wBAAwBA,CAEtCC,IAAgC,EAChC;EACA,IAAI,CAACC,KAAK,CAACD,IAAI,CAACE,GAAG,CAAC;EACpB,IAAI,CAACD,KAAK,CAACD,IAAI,CAACG,cAAc,CAAC;EAC/B,IAAI,CAACF,KAAK,CAACD,IAAI,CAACI,KAAK,CAAC;AACxB;AAEO,SAASC,eAAeA,CAAA,EAAgB;EAC7C,MAAM,IAAIC,KAAK,CAAC,wDAAwD,CAAC;AAC3E;AAEO,SAASC,eAAeA,CAAgBP,IAAuB,EAAE;EACtE,MAAMQ,MAAM,GAAGR,IAAI,CAACQ,MAAM;EAE1B,IAAIC,OAAO,GAAG,GAAG;EAEjB,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGF,MAAM,CAACG,MAAM,EAAED,CAAC,EAAE,EAAE;IACtCD,OAAO,IAAID,MAAM,CAACE,CAAC,CAAC,CAACE,KAAK,CAACC,GAAG;IAE9B,IAAIH,CAAC,GAAG,CAAC,GAAGF,MAAM,CAACG,MAAM,EAAE;MACzB,IAAI,CAACG,KAAK,CAACL,OAAO,GAAG,IAAI,EAAE,IAAI,CAAC;MAChC,IAAI,CAACR,KAAK,CAACD,IAAI,CAACe,WAAW,CAACL,CAAC,CAAC,CAAC;MAC/BD,OAAO,GAAG,GAAG;MAIb,IAAqC,IAAI,CAACO,QAAQ,EAAE;QAClD,MAAMF,KAAK,GAAG,IAAI,CAACE,QAAQ,CAACC,YAAY,CAACjB,IAAI,EAAE,GAAG,EAAEU,CAAC,CAAC;QACtD,IAAII,KAAK,EAAE,IAAI,CAACI,UAAU,CAACJ,KAAK,CAACK,GAAG,CAACC,KAAK,CAAC;MAC7C;IACF;EACF;EAEA,IAAI,CAACN,KAAK,CAACL,OAAO,GAAG,GAAG,EAAE,IAAI,CAAC;AACjC","ignoreList":[]}1 {"version":3,"names":["TaggedTemplateExpression","node","print","tag","typeParameters","quasi","TemplateElement","Error","TemplateLiteral","quasis","partRaw","i","length","value","raw","token","expressions","tokenMap","findMatching","_catchUpTo","loc","start"],"sources":["../../src/generators/template-literals.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function TaggedTemplateExpression(\n this: Printer,\n node: t.TaggedTemplateExpression,\n) {\n this.print(node.tag);\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n this.print(node.typeArguments);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST\n this.print(node.typeParameters);\n }\n this.print(node.quasi);\n}\n\nexport function TemplateElement(this: Printer) {\n throw new Error(\"TemplateElement printing is handled in TemplateLiteral\");\n}\n\nexport function TemplateLiteral(this: Printer, node: t.TemplateLiteral) {\n const quasis = node.quasis;\n\n let partRaw = \"`\";\n\n for (let i = 0; i < quasis.length; i++) {\n partRaw += quasis[i].value.raw;\n\n if (i + 1 < quasis.length) {\n this.token(partRaw + \"${\", true);\n this.print(node.expressions[i]);\n partRaw = \"}\";\n\n // In Babel 7 we have indivirual tokens for ${ and }, so the automatic\n // catchup logic does not work. Manually look for those tokens.\n if (!process.env.BABEL_8_BREAKING && this.tokenMap) {\n const token = this.tokenMap.findMatching(node, \"}\", i);\n if (token) this._catchUpTo(token.loc.start);\n }\n }\n }\n\n this.token(partRaw + \"`\", true);\n}\n"],"mappings":";;;;;;;;AAGO,SAASA,wBAAwBA,CAEtCC,IAAgC,EAChC;EACA,IAAI,CAACC,KAAK,CAACD,IAAI,CAACE,GAAG,CAAC;EAIb;IAEL,IAAI,CAACD,KAAK,CAACD,IAAI,CAACG,cAAc,CAAC;EACjC;EACA,IAAI,CAACF,KAAK,CAACD,IAAI,CAACI,KAAK,CAAC;AACxB;AAEO,SAASC,eAAeA,CAAA,EAAgB;EAC7C,MAAM,IAAIC,KAAK,CAAC,wDAAwD,CAAC;AAC3E;AAEO,SAASC,eAAeA,CAAgBP,IAAuB,EAAE;EACtE,MAAMQ,MAAM,GAAGR,IAAI,CAACQ,MAAM;EAE1B,IAAIC,OAAO,GAAG,GAAG;EAEjB,KAAK,IAAIC,CAAC,GAAG,CAAC,EAAEA,CAAC,GAAGF,MAAM,CAACG,MAAM,EAAED,CAAC,EAAE,EAAE;IACtCD,OAAO,IAAID,MAAM,CAACE,CAAC,CAAC,CAACE,KAAK,CAACC,GAAG;IAE9B,IAAIH,CAAC,GAAG,CAAC,GAAGF,MAAM,CAACG,MAAM,EAAE;MACzB,IAAI,CAACG,KAAK,CAACL,OAAO,GAAG,IAAI,EAAE,IAAI,CAAC;MAChC,IAAI,CAACR,KAAK,CAACD,IAAI,CAACe,WAAW,CAACL,CAAC,CAAC,CAAC;MAC/BD,OAAO,GAAG,GAAG;MAIb,IAAqC,IAAI,CAACO,QAAQ,EAAE;QAClD,MAAMF,KAAK,GAAG,IAAI,CAACE,QAAQ,CAACC,YAAY,CAACjB,IAAI,EAAE,GAAG,EAAEU,CAAC,CAAC;QACtD,IAAII,KAAK,EAAE,IAAI,CAACI,UAAU,CAACJ,KAAK,CAACK,GAAG,CAACC,KAAK,CAAC;MAC7C;IACF;EACF;EAEA,IAAI,CAACN,KAAK,CAACL,OAAO,GAAG,GAAG,EAAE,IAAI,CAAC;AACjC","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/types.js
r0c6b92a r79a0317 8 8 exports.BigIntLiteral = BigIntLiteral; 9 9 exports.BooleanLiteral = BooleanLiteral; 10 exports.DecimalLiteral = DecimalLiteral;11 10 exports.Identifier = Identifier; 12 11 exports.NullLiteral = NullLiteral; … … 64 63 const exit = this.enterDelimited(); 65 64 this.space(); 66 this.printList(props, { 67 indent: true, 68 statement: true, 69 printTrailingSeparator: this.shouldPrintTrailingComma("}") 70 }); 65 this.printList(props, this.shouldPrintTrailingComma("}"), true, true); 71 66 this.space(); 72 67 exit(); … … 139 134 if (props.length) { 140 135 this.space(); 141 this.printList(props, { 142 indent: true, 143 statement: true, 144 printTrailingSeparator: this.shouldPrintTrailingComma(endToken) 145 }); 136 this.printList(props, this.shouldPrintTrailingComma(endToken), true, true); 146 137 this.space(); 147 138 } … … 218 209 this.word(node.value + "n"); 219 210 } 220 function DecimalLiteral(node) {221 const raw = this.getPossibleRaw(node);222 if (!this.format.minified && raw !== undefined) {223 this.word(raw);224 return;225 }226 this.word(node.value + "m");227 }228 211 const validTopicTokenSet = new Set(["^^", "@@", "^", "%", "#"]); 229 212 function TopicReference() { -
imaps-frontend/node_modules/@babel/generator/lib/generators/types.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_jsesc","isAssignmentPattern","isIdentifier","lastRawIdentNode","lastRawIdentResult","_getRawIdentifier","node","name","token","tokenMap","find","tok","value","_originalCode","slice","start","end","Identifier","_node$loc","sourceIdentifierName","loc","identifierName","word","ArgumentPlaceholder","RestElement","print","argument","ObjectExpression","props","properties","length","exit","enterDelimited","space","printList"," indent","statement","printTrailingSeparator","shouldPrintTrailingComma","sourceWithOffset","ObjectMethod","printJoin","decorators","_methodHead","body","ObjectProperty","computed","key","left","shorthand","ArrayExpression","elems","elements","len","i","elem","RecordExpression","startToken","endToken","format","recordAndTupleSyntaxType","Error","JSON","stringify","TupleExpression","RegExpLiteral","pattern","flags","BooleanLiteral","NullLiteral","NumericLiteral","raw","getPossibleRaw","opts","jsescOption","str","numbers","number","jsesc","minified","StringLiteral","undefined","val","BigIntLiteral","DecimalLiteral","validTopicTokenSet","Set","TopicReference","topicToken","has","givenTopicTokenJSON","validTopics","Array","from","v","join","PipelineTopicExpression","expression","PipelineBareFunction","callee","PipelinePrimaryTopicReference"],"sources":["../../src/generators/types.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport { isAssignmentPattern, isIdentifier } from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport jsesc from \"jsesc\";\n\nlet lastRawIdentNode: t.Identifier | null = null;\nlet lastRawIdentResult: string = \"\";\nexport function _getRawIdentifier(this: Printer, node: t.Identifier) {\n if (node === lastRawIdentNode) return lastRawIdentResult;\n lastRawIdentNode = node;\n\n const { name } = node;\n const token = this.tokenMap.find(node, tok => tok.value === name);\n if (token) {\n lastRawIdentResult = this._originalCode.slice(token.start, token.end);\n return lastRawIdentResult;\n }\n return (lastRawIdentResult = node.name);\n}\n\nexport function Identifier(this: Printer, node: t.Identifier) {\n this.sourceIdentifierName(node.loc?.identifierName || node.name);\n\n this.word(this.tokenMap ? this._getRawIdentifier(node) : node.name);\n}\n\nexport function ArgumentPlaceholder(this: Printer) {\n this.token(\"?\");\n}\n\nexport function RestElement(this: Printer, node: t.RestElement) {\n this.token(\"...\");\n this.print(node.argument);\n}\n\nexport { RestElement as SpreadElement };\n\nexport function ObjectExpression(this: Printer, node: t.ObjectExpression) {\n const props = node.properties;\n\n this.token(\"{\");\n\n if (props.length) {\n const exit = this.enterDelimited();\n this.space();\n this.printList(props, {\n indent: true,\n statement: true,\n printTrailingSeparator: this.shouldPrintTrailingComma(\"}\"),\n });\n this.space();\n exit();\n }\n\n this.sourceWithOffset(\"end\", node.loc, -1);\n\n this.token(\"}\");\n}\n\nexport { ObjectExpression as ObjectPattern };\n\nexport function ObjectMethod(this: Printer, node: t.ObjectMethod) {\n this.printJoin(node.decorators);\n this._methodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function ObjectProperty(this: Printer, node: t.ObjectProperty) {\n this.printJoin(node.decorators);\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n // print `({ foo: foo = 5 } = {})` as `({ foo = 5 } = {});`\n if (\n isAssignmentPattern(node.value) &&\n isIdentifier(node.key) &&\n // @ts-expect-error todo(flow->ts) `.name` does not exist on some types in union\n node.key.name === node.value.left.name\n ) {\n this.print(node.value);\n return;\n }\n\n this.print(node.key);\n\n // shorthand!\n if (\n node.shorthand &&\n isIdentifier(node.key) &&\n isIdentifier(node.value) &&\n node.key.name === node.value.name\n ) {\n return;\n }\n }\n\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ArrayExpression(this: Printer, node: t.ArrayExpression) {\n const elems = node.elements;\n const len = elems.length;\n\n this.token(\"[\");\n\n const exit = this.enterDelimited();\n\n for (let i = 0; i < elems.length; i++) {\n const elem = elems[i];\n if (elem) {\n if (i > 0) this.space();\n this.print(elem);\n if (i < len - 1 || this.shouldPrintTrailingComma(\"]\")) {\n this.token(\",\", false, i);\n }\n } else {\n // If the array expression ends with a hole, that hole\n // will be ignored by the interpreter, but if it ends with\n // two (or more) holes, we need to write out two (or more)\n // commas so that the resulting code is interpreted with\n // both (all) of the holes.\n this.token(\",\", false, i);\n }\n }\n\n exit();\n\n this.token(\"]\");\n}\n\nexport { ArrayExpression as ArrayPattern };\n\nexport function RecordExpression(this: Printer, node: t.RecordExpression) {\n const props = node.properties;\n\n let startToken;\n let endToken;\n if (process.env.BABEL_8_BREAKING) {\n startToken = \"#{\";\n endToken = \"}\";\n } else {\n if (this.format.recordAndTupleSyntaxType === \"bar\") {\n startToken = \"{|\";\n endToken = \"|}\";\n } else if (\n this.format.recordAndTupleSyntaxType !== \"hash\" &&\n this.format.recordAndTupleSyntaxType != null\n ) {\n throw new Error(\n `The \"recordAndTupleSyntaxType\" generator option must be \"bar\" or \"hash\" (${JSON.stringify(\n this.format.recordAndTupleSyntaxType,\n )} received).`,\n );\n } else {\n startToken = \"#{\";\n endToken = \"}\";\n }\n }\n\n this.token(startToken);\n\n if (props.length) {\n this.space();\n this.printList(props, {\n indent: true,\n statement: true,\n printTrailingSeparator: this.shouldPrintTrailingComma(endToken),\n });\n this.space();\n }\n this.token(endToken);\n}\n\nexport function TupleExpression(this: Printer, node: t.TupleExpression) {\n const elems = node.elements;\n const len = elems.length;\n\n let startToken;\n let endToken;\n if (process.env.BABEL_8_BREAKING) {\n startToken = \"#[\";\n endToken = \"]\";\n } else {\n if (this.format.recordAndTupleSyntaxType === \"bar\") {\n startToken = \"[|\";\n endToken = \"|]\";\n } else if (this.format.recordAndTupleSyntaxType === \"hash\") {\n startToken = \"#[\";\n endToken = \"]\";\n } else {\n throw new Error(\n `${this.format.recordAndTupleSyntaxType} is not a valid recordAndTuple syntax type`,\n );\n }\n }\n\n this.token(startToken);\n\n for (let i = 0; i < elems.length; i++) {\n const elem = elems[i];\n if (elem) {\n if (i > 0) this.space();\n this.print(elem);\n if (i < len - 1 || this.shouldPrintTrailingComma(endToken)) {\n this.token(\",\", false, i);\n }\n }\n }\n\n this.token(endToken);\n}\n\nexport function RegExpLiteral(this: Printer, node: t.RegExpLiteral) {\n this.word(`/${node.pattern}/${node.flags}`);\n}\n\nexport function BooleanLiteral(this: Printer, node: t.BooleanLiteral) {\n this.word(node.value ? \"true\" : \"false\");\n}\n\nexport function NullLiteral(this: Printer) {\n this.word(\"null\");\n}\n\nexport function NumericLiteral(this: Printer, node: t.NumericLiteral) {\n const raw = this.getPossibleRaw(node);\n const opts = this.format.jsescOption;\n const value = node.value;\n const str = value + \"\";\n if (opts.numbers) {\n this.number(jsesc(value, opts), value);\n } else if (raw == null) {\n this.number(str, value); // normalize\n } else if (this.format.minified) {\n this.number(raw.length < str.length ? raw : str, value);\n } else {\n this.number(raw, value);\n }\n}\n\nexport function StringLiteral(this: Printer, node: t.StringLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.token(raw);\n return;\n }\n\n const val = jsesc(node.value, this.format.jsescOption);\n\n this.token(val);\n}\n\nexport function BigIntLiteral(this: Printer, node: t.BigIntLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.word(raw);\n return;\n }\n this.word(node.value + \"n\");\n}\n\n// TODO: Remove in Babel 8\nexport function DecimalLiteral(this: Printer, node: any) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.word(raw);\n return;\n }\n this.word(node.value + \"m\");\n}\n\n// Hack pipe operator\nconst validTopicTokenSet = new Set([\"^^\", \"@@\", \"^\", \"%\", \"#\"]);\nexport function TopicReference(this: Printer) {\n const { topicToken } = this.format;\n\n if (validTopicTokenSet.has(topicToken)) {\n this.token(topicToken);\n } else {\n const givenTopicTokenJSON = JSON.stringify(topicToken);\n const validTopics = Array.from(validTopicTokenSet, v => JSON.stringify(v));\n throw new Error(\n `The \"topicToken\" generator option must be one of ` +\n `${validTopics.join(\", \")} (${givenTopicTokenJSON} received instead).`,\n );\n }\n}\n\n// Smart-mix pipe operator\nexport function PipelineTopicExpression(\n this: Printer,\n node: t.PipelineTopicExpression,\n) {\n this.print(node.expression);\n}\n\nexport function PipelineBareFunction(\n this: Printer,\n node: t.PipelineBareFunction,\n) {\n this.print(node.callee);\n}\n\nexport function PipelinePrimaryTopicReference(this: Printer) {\n this.token(\"#\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAA0B;EAFjBE,mBAAmB;EAAEC;AAAY,IAAAJ,EAAA;AAI1C,IAAIK,gBAAqC,GAAG,IAAI;AAChD,IAAIC,kBAA0B,GAAG,EAAE;AAC5B,SAASC,iBAAiBA,CAAgBC,IAAkB,EAAE;E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AASM,uBAAuBA,CAErC1F,IAA+B,EAC/B;EACA,IAAI,CAACmB,KAAK,CAACnB,IAAI,CAAC2F,UAAU,CAAC;AAC7B;AAEO,SAASC,oBAAoBA,CAElC5F,IAA4B,EAC5B;EACA,IAAI,CAACmB,KAAK,CAACnB,IAAI,CAAC6F,MAAM,CAAC;AACzB;AAEO,SAASC,6BAA6BA,CAAA,EAAgB;EAC3D,IAAI,CAAC5F,SAAK,GAAI,CAAC;AACjB","ignoreList":[]}1 {"version":3,"names":["_t","require","_jsesc","isAssignmentPattern","isIdentifier","lastRawIdentNode","lastRawIdentResult","_getRawIdentifier","node","name","token","tokenMap","find","tok","value","_originalCode","slice","start","end","Identifier","_node$loc","sourceIdentifierName","loc","identifierName","word","ArgumentPlaceholder","RestElement","print","argument","ObjectExpression","props","properties","length","exit","enterDelimited","space","printList","shouldPrintTrailingComma","sourceWithOffset","ObjectMethod","printJoin","decorators","_methodHead","body","ObjectProperty","computed","key","left","shorthand","ArrayExpression","elems","elements","len","i","elem","RecordExpression","startToken","endToken","format","recordAndTupleSyntaxType","Error","JSON","stringify","TupleExpression","RegExpLiteral","pattern","flags","BooleanLiteral","NullLiteral","NumericLiteral","raw","getPossibleRaw","opts","jsescOption","str","numbers","number","jsesc","minified","StringLiteral","undefined","val","BigIntLiteral","validTopicTokenSet","Set","TopicReference","topicToken","has","givenTopicTokenJSON","validTopics","Array","from","v","join","PipelineTopicExpression","expression","PipelineBareFunction","callee","PipelinePrimaryTopicReference"],"sources":["../../src/generators/types.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport { isAssignmentPattern, isIdentifier } from \"@babel/types\";\nimport type * as t from \"@babel/types\";\nimport jsesc from \"jsesc\";\n\nlet lastRawIdentNode: t.Identifier | null = null;\nlet lastRawIdentResult: string = \"\";\nexport function _getRawIdentifier(this: Printer, node: t.Identifier) {\n if (node === lastRawIdentNode) return lastRawIdentResult;\n lastRawIdentNode = node;\n\n const { name } = node;\n const token = this.tokenMap.find(node, tok => tok.value === name);\n if (token) {\n lastRawIdentResult = this._originalCode.slice(token.start, token.end);\n return lastRawIdentResult;\n }\n return (lastRawIdentResult = node.name);\n}\n\nexport function Identifier(this: Printer, node: t.Identifier) {\n this.sourceIdentifierName(node.loc?.identifierName || node.name);\n\n this.word(this.tokenMap ? this._getRawIdentifier(node) : node.name);\n}\n\nexport function ArgumentPlaceholder(this: Printer) {\n this.token(\"?\");\n}\n\nexport function RestElement(this: Printer, node: t.RestElement) {\n this.token(\"...\");\n this.print(node.argument);\n}\n\nexport { RestElement as SpreadElement };\n\nexport function ObjectExpression(this: Printer, node: t.ObjectExpression) {\n const props = node.properties;\n\n this.token(\"{\");\n\n if (props.length) {\n const exit = this.enterDelimited();\n this.space();\n this.printList(props, this.shouldPrintTrailingComma(\"}\"), true, true);\n this.space();\n exit();\n }\n\n this.sourceWithOffset(\"end\", node.loc, -1);\n\n this.token(\"}\");\n}\n\nexport { ObjectExpression as ObjectPattern };\n\nexport function ObjectMethod(this: Printer, node: t.ObjectMethod) {\n this.printJoin(node.decorators);\n this._methodHead(node);\n this.space();\n this.print(node.body);\n}\n\nexport function ObjectProperty(this: Printer, node: t.ObjectProperty) {\n this.printJoin(node.decorators);\n\n if (node.computed) {\n this.token(\"[\");\n this.print(node.key);\n this.token(\"]\");\n } else {\n // print `({ foo: foo = 5 } = {})` as `({ foo = 5 } = {});`\n if (\n isAssignmentPattern(node.value) &&\n isIdentifier(node.key) &&\n // @ts-expect-error todo(flow->ts) `.name` does not exist on some types in union\n node.key.name === node.value.left.name\n ) {\n this.print(node.value);\n return;\n }\n\n this.print(node.key);\n\n // shorthand!\n if (\n node.shorthand &&\n isIdentifier(node.key) &&\n isIdentifier(node.value) &&\n node.key.name === node.value.name\n ) {\n return;\n }\n }\n\n this.token(\":\");\n this.space();\n this.print(node.value);\n}\n\nexport function ArrayExpression(this: Printer, node: t.ArrayExpression) {\n const elems = node.elements;\n const len = elems.length;\n\n this.token(\"[\");\n\n const exit = this.enterDelimited();\n\n for (let i = 0; i < elems.length; i++) {\n const elem = elems[i];\n if (elem) {\n if (i > 0) this.space();\n this.print(elem);\n if (i < len - 1 || this.shouldPrintTrailingComma(\"]\")) {\n this.token(\",\", false, i);\n }\n } else {\n // If the array expression ends with a hole, that hole\n // will be ignored by the interpreter, but if it ends with\n // two (or more) holes, we need to write out two (or more)\n // commas so that the resulting code is interpreted with\n // both (all) of the holes.\n this.token(\",\", false, i);\n }\n }\n\n exit();\n\n this.token(\"]\");\n}\n\nexport { ArrayExpression as ArrayPattern };\n\nexport function RecordExpression(this: Printer, node: t.RecordExpression) {\n const props = node.properties;\n\n let startToken;\n let endToken;\n if (process.env.BABEL_8_BREAKING) {\n startToken = \"#{\";\n endToken = \"}\";\n } else {\n if (this.format.recordAndTupleSyntaxType === \"bar\") {\n startToken = \"{|\";\n endToken = \"|}\";\n } else if (\n this.format.recordAndTupleSyntaxType !== \"hash\" &&\n this.format.recordAndTupleSyntaxType != null\n ) {\n throw new Error(\n `The \"recordAndTupleSyntaxType\" generator option must be \"bar\" or \"hash\" (${JSON.stringify(\n this.format.recordAndTupleSyntaxType,\n )} received).`,\n );\n } else {\n startToken = \"#{\";\n endToken = \"}\";\n }\n }\n\n this.token(startToken);\n\n if (props.length) {\n this.space();\n this.printList(props, this.shouldPrintTrailingComma(endToken), true, true);\n this.space();\n }\n this.token(endToken);\n}\n\nexport function TupleExpression(this: Printer, node: t.TupleExpression) {\n const elems = node.elements;\n const len = elems.length;\n\n let startToken;\n let endToken;\n if (process.env.BABEL_8_BREAKING) {\n startToken = \"#[\";\n endToken = \"]\";\n } else {\n if (this.format.recordAndTupleSyntaxType === \"bar\") {\n startToken = \"[|\";\n endToken = \"|]\";\n } else if (this.format.recordAndTupleSyntaxType === \"hash\") {\n startToken = \"#[\";\n endToken = \"]\";\n } else {\n throw new Error(\n `${this.format.recordAndTupleSyntaxType} is not a valid recordAndTuple syntax type`,\n );\n }\n }\n\n this.token(startToken);\n\n for (let i = 0; i < elems.length; i++) {\n const elem = elems[i];\n if (elem) {\n if (i > 0) this.space();\n this.print(elem);\n if (i < len - 1 || this.shouldPrintTrailingComma(endToken)) {\n this.token(\",\", false, i);\n }\n }\n }\n\n this.token(endToken);\n}\n\nexport function RegExpLiteral(this: Printer, node: t.RegExpLiteral) {\n this.word(`/${node.pattern}/${node.flags}`);\n}\n\nexport function BooleanLiteral(this: Printer, node: t.BooleanLiteral) {\n this.word(node.value ? \"true\" : \"false\");\n}\n\nexport function NullLiteral(this: Printer) {\n this.word(\"null\");\n}\n\nexport function NumericLiteral(this: Printer, node: t.NumericLiteral) {\n const raw = this.getPossibleRaw(node);\n const opts = this.format.jsescOption;\n const value = node.value;\n const str = value + \"\";\n if (opts.numbers) {\n this.number(jsesc(value, opts), value);\n } else if (raw == null) {\n this.number(str, value); // normalize\n } else if (this.format.minified) {\n this.number(raw.length < str.length ? raw : str, value);\n } else {\n this.number(raw, value);\n }\n}\n\nexport function StringLiteral(this: Printer, node: t.StringLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.token(raw);\n return;\n }\n\n const val = jsesc(node.value, this.format.jsescOption);\n\n this.token(val);\n}\n\nexport function BigIntLiteral(this: Printer, node: t.BigIntLiteral) {\n const raw = this.getPossibleRaw(node);\n if (!this.format.minified && raw !== undefined) {\n this.word(raw);\n return;\n }\n this.word(node.value + \"n\");\n}\n\n// Hack pipe operator\nconst validTopicTokenSet = new Set([\"^^\", \"@@\", \"^\", \"%\", \"#\"]);\nexport function TopicReference(this: Printer) {\n const { topicToken } = this.format;\n\n if (validTopicTokenSet.has(topicToken)) {\n this.token(topicToken);\n } else {\n const givenTopicTokenJSON = JSON.stringify(topicToken);\n const validTopics = Array.from(validTopicTokenSet, v => JSON.stringify(v));\n throw new Error(\n `The \"topicToken\" generator option must be one of ` +\n `${validTopics.join(\", \")} (${givenTopicTokenJSON} received instead).`,\n );\n }\n}\n\n// Smart-mix pipe operator\nexport function PipelineTopicExpression(\n this: Printer,\n node: t.PipelineTopicExpression,\n) {\n this.print(node.expression);\n}\n\nexport function PipelineBareFunction(\n this: Printer,\n node: t.PipelineBareFunction,\n) {\n this.print(node.callee);\n}\n\nexport function PipelinePrimaryTopicReference(this: Printer) {\n this.token(\"#\");\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AACA,IAAAA,EAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAA0B;EAFjBE,mBAAmB;EAAEC;AAAY,IAAAJ,EAAA;AAI1C,IAAIK,gBAAqC,GAAG,IAAI;AAChD,IAAIC,kBAA0B,GAAG,EAAE;AAC5B,SAASC,iBAAiBA,CAAgBC,IAAkB,EAAE;EACnE,IAAIA,IAAI,KAAKH,gBAAgB,EAAE,OAAOC,kBAAkB;EACxDD,gBAAgB,GAAGG,IAAI;EAEvB,MAAM;IAAEC;EAAK,CAAC,GAAGD,IAAI;EACrB,MAAME,KAAK,GAAG,IAAI,CAACC,QAAQ,CAACC,IAAI,CAACJ,IAAI,EAAEK,GAAG,IAAIA,GAAG,CAACC,KAAK,KAAKL,IAAI,CAAC;EACjE,IAAIC,KAAK,EAAE;IACTJ,kBAAkB,GAAG,IAAI,CAACS,aAAa,CAACC,KAAK,CAACN,KAAK,CAACO,KAAK,EAAEP,KAAK,CAACQ,GAAG,CAAC;IACrE,OAAOZ,kBAAkB;EAC3B;EACA,OAAQA,kBAAkB,GAAGE,IAAI,CAACC,IAAI;AACxC;AAEO,SAASU,UAAUA,CAAgBX,IAAkB,EAAE;EAAA,IAAAY,SAAA;EAC5D,IAAI,CAACC,oBAAoB,CAAC,EAAAD,SAAA,GAAAZ,IAAI,CAACc,GAAG,qBAARF,SAAA,CAAUG,cAAc,KAAIf,IAAI,CAACC,IAAI,CAAC;EAEhE,IAAI,CAACe,IAAI,CAAC,IAAI,CAACb,QAAQ,GAAG,IAAI,CAACJ,iBAAiB,CAACC,IAAI,CAAC,GAAGA,IAAI,CAACC,IAAI,CAAC;AACr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BACrD,CAAC;EACH;AACF;AAGO,SAASM,uBAAuBA,CAErCtF,IAA+B,EAC/B;EACA,IAAI,CAACmB,KAAK,CAACnB,IAAI,CAACuF,UAAU,CAAC;AAC7B;AAEO,SAASC,oBAAoBA,CAElCxF,IAA4B,EAC5B;EACA,IAAI,CAACmB,KAAK,CAACnB,IAAI,CAACyF,MAAM,CAAC;AACzB;AAEO,SAASC,6BAA6BA,CAAA,EAAgB;EAC3D,IAAI,CAACxF,SAAK,GAAI,CAAC;AACjB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/generators/typescript.js
r0c6b92a r79a0317 10 10 exports.TSBooleanKeyword = TSBooleanKeyword; 11 11 exports.TSCallSignatureDeclaration = TSCallSignatureDeclaration; 12 exports.TSInterfaceHeritage = exports.TS ExpressionWithTypeArguments = exports.TSClassImplements = TSClassImplements;12 exports.TSInterfaceHeritage = exports.TSClassImplements = TSClassImplements; 13 13 exports.TSConditionalType = TSConditionalType; 14 14 exports.TSConstructSignatureDeclaration = TSConstructSignatureDeclaration; … … 16 16 exports.TSDeclareFunction = TSDeclareFunction; 17 17 exports.TSDeclareMethod = TSDeclareMethod; 18 exports.TSEnumBody = TSEnumBody; 18 19 exports.TSEnumDeclaration = TSEnumDeclaration; 19 20 exports.TSEnumMember = TSEnumMember; … … 84 85 printTrailingSeparator || (printTrailingSeparator = this.shouldPrintTrailingComma(">")); 85 86 } 86 this.printList(node.params, { 87 printTrailingSeparator 88 }); 87 this.printList(node.params, printTrailingSeparator); 89 88 this.tokenChar(62); 90 89 } … … 282 281 } 283 282 function TSTypeReference(node) { 284 this.print(node.typeName, !!node.typeParameters); 285 this.print(node.typeParameters); 283 const typeArguments = node.typeParameters; 284 this.print(node.typeName, !!typeArguments); 285 this.print(typeArguments); 286 286 } 287 287 function TSTypePredicate(node) { … … 302 302 this.space(); 303 303 this.print(node.exprName); 304 if (node.typeParameters) { 305 this.print(node.typeParameters); 304 const typeArguments = node.typeParameters; 305 if (typeArguments) { 306 this.print(typeArguments); 306 307 } 307 308 } 308 309 function TSTypeLiteral(node) { 309 printBraced(this, node, () => this.printJoin(node.members, { 310 indent: true, 311 statement: true 312 })); 310 printBraced(this, node, () => this.printJoin(node.members, true, true)); 313 311 } 314 312 function TSArrayType(node) { … … 319 317 function TSTupleType(node) { 320 318 this.tokenChar(91); 321 this.printList(node.elementTypes, { 322 printTrailingSeparator: this.shouldPrintTrailingComma("]") 323 }); 319 this.printList(node.elementTypes, this.shouldPrintTrailingComma("]")); 324 320 this.tokenChar(93); 325 321 } … … 352 348 printer.token(sep); 353 349 } 354 printer.printJoin(node.types, { 355 separator(i) { 356 this.space(); 357 this.token(sep, null, i + hasLeadingToken); 358 this.space(); 359 } 350 printer.printJoin(node.types, undefined, undefined, function (i) { 351 this.space(); 352 this.token(sep, null, i + hasLeadingToken); 353 this.space(); 360 354 }); 361 355 } … … 450 444 function TSClassImplements(node) { 451 445 this.print(node.expression); 452 this.print(node.type Parameters);446 this.print(node.typeArguments); 453 447 } 454 448 function TSInterfaceDeclaration(node) { … … 478 472 } 479 473 function TSInterfaceBody(node) { 480 printBraced(this, node, () => this.printJoin(node.body, { 481 indent: true, 482 statement: true 483 })); 474 printBraced(this, node, () => this.printJoin(node.body, true, true)); 484 475 } 485 476 function TSTypeAliasDeclaration(node) { … … 529 520 function TSInstantiationExpression(node) { 530 521 this.print(node.expression); 531 this.print(node.typeParameters); 522 { 523 this.print(node.typeParameters); 524 } 532 525 } 533 526 function TSEnumDeclaration(node) { … … 535 528 declare, 536 529 const: isConst, 537 id, 538 members 530 id 539 531 } = node; 540 532 if (declare) { … … 550 542 this.print(id); 551 543 this.space(); 544 { 545 TSEnumBody.call(this, node); 546 } 547 } 548 function TSEnumBody(node) { 552 549 printBraced(this, node, () => { 553 550 var _this$shouldPrintTrai; 554 return this.printList(members, { 555 indent: true, 556 statement: true, 557 printTrailingSeparator: (_this$shouldPrintTrai = this.shouldPrintTrailingComma("}")) != null ? _this$shouldPrintTrai : true 558 }); 551 return this.printList(node.members, (_this$shouldPrintTrai = this.shouldPrintTrailingComma("}")) != null ? _this$shouldPrintTrai : true, true, true); 559 552 }); 560 553 } … … 582 575 this.space(); 583 576 } 584 if (!node.global) { 585 this.word(kind != null ? kind : id.type === "Identifier" ? "namespace" : "module"); 586 this.space(); 587 } 588 this.print(id); 589 if (!node.body) { 590 this.semicolon(); 591 return; 592 } 593 let body = node.body; 594 while (body.type === "TSModuleDeclaration") { 595 this.tokenChar(46); 596 this.print(body.id); 597 body = body.body; 598 } 599 this.space(); 600 this.print(body); 577 { 578 if (!node.global) { 579 this.word(kind != null ? kind : id.type === "Identifier" ? "namespace" : "module"); 580 this.space(); 581 } 582 this.print(id); 583 if (!node.body) { 584 this.semicolon(); 585 return; 586 } 587 let body = node.body; 588 while (body.type === "TSModuleDeclaration") { 589 this.tokenChar(46); 590 this.print(body.id); 591 body = body.body; 592 } 593 this.space(); 594 this.print(body); 595 } 601 596 } 602 597 function TSModuleBlock(node) { 603 printBraced(this, node, () => this.printSequence(node.body, { 604 indent: true 605 })); 598 printBraced(this, node, () => this.printSequence(node.body, true)); 606 599 } 607 600 function TSImportType(node) { … … 609 602 argument, 610 603 qualifier, 611 typeParameters604 options 612 605 } = node; 613 606 this.word("import"); 614 607 this.tokenChar(40); 615 608 this.print(argument); 609 if (options) { 610 this.tokenChar(44); 611 this.print(options); 612 } 616 613 this.tokenChar(41); 617 614 if (qualifier) { … … 619 616 this.print(qualifier); 620 617 } 621 if (typeParameters) { 622 this.print(typeParameters); 618 const typeArguments = node.typeParameters; 619 if (typeArguments) { 620 this.print(typeArguments); 623 621 } 624 622 } -
imaps-frontend/node_modules/@babel/generator/lib/generators/typescript.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["TSTypeAnnotation","node","parent","token","type","typeAnnotation","space","optional","print","TSTypeParameterInstantiation","printTrailingSeparator","params","length","tokenMap","start","end","find","t","matchesOriginal","shouldPrintTrailingComma","printList","TSTypeParameter","in","word","out","name","constraint","default","TSParameterProperty","accessibility","readonly","_param","parameter","TSDeclareFunction","declare","_functionHead","semicolon","TSDeclareMethod","_classMethodHead","TSQualifiedName","left","right","TSCallSignatureDeclaration","tsPrintSignatureDeclarationBase","maybePrintTrailingCommaOrSemicolon","printer","endMatches","TSConstructSignatureDeclaration","TSPropertySignature","tsPrintPropertyOrMethodName","computed","key","TSMethodSignature","kind","TSIndexSignature","static","isStatic","_parameters","parameters","TSAnyKeyword","TSBigIntKeyword","TSUnknownKeyword","TSNumberKeyword","TSObjectKeyword","TSBooleanKeyword","TSStringKeyword","TSSymbolKeyword","TSVoidKeyword","TSUndefinedKeyword","TSNullKeyword","TSNeverKeyword","TSIntrinsicKeyword","TSThisType","TSFunctionType","tsPrintFunctionOrConstructorType","TSConstructorType","abstract","typeParameters","returnType","TSTypeReference","type Name","TSTypePredicate","asserts","parameterName","TSTypeQuery","exprName","TSTypeLiteral","printBraced","printJoin","members","indent","statement","TSArrayType","elementType","TSTupleType","elementTypes","TSOptionalType","TSRestType","TSNamedTupleMember","label","TSUnionType","tsPrintUnionOrIntersectionType","TSIntersectionType","sep","_printer$tokenMap","hasLeadingToken","startMatches","types","separator","i","TSConditionalType","checkType","extendsType","trueType","falseType","TSInferType","typeParameter","TSParenthesizedType","TSTypeOperator","operator","TSIndexedAccessType","objectType","indexType","TSMappedType","nameType","exit","enterDelimited","tokenIfPlusMinus","self","tok","TSLiteralType","literal","TSClassImplements","expression","TSInterfaceDeclaration","id","extends","extendz","body","TSInterfaceBody","TSTypeAliasDeclaration","TSTypeExpression","TSTypeAssertion","TSInstantiationExpression","TSEnumDeclaration","const","isConst","_this$shouldPrintTrai","TSEnumMember","initializer","TSModuleDeclaration","global","TSModuleBlock","printSequence","TSImportType","argument","qualifier","TSImportEqualsDeclaration","isExport","moduleReference","TSExternalModuleReference","TSNonNullExpression","TSExportAssignment","TSNamespaceExportDeclaration","tsPrintClassMemberModifiers","isField","printModifiersList","override","cb","rightBrace","modifiers","_printer$tokenMap2","modifiersSet","Set","modifier","add","has","value","delete","size"],"sources":["../../src/generators/typescript.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function TSTypeAnnotation(\n this: Printer,\n node: t.TSTypeAnnotation,\n parent: t.Node,\n) {\n // TODO(@nicolo-ribaudo): investigate not including => in the range\n // of the return type of an arrow function type\n this.token(\n (parent.type === \"TSFunctionType\" || parent.type === \"TSConstructorType\") &&\n (process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n parent.returnType\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n parent.typeAnnotation) === node\n ? \"=>\"\n : \":\",\n );\n this.space();\n // @ts-expect-error todo(flow->ts) can this be removed? `.optional` looks to be not existing property\n if (node.optional) this.token(\"?\");\n this.print(node.typeAnnotation);\n}\n\nexport function TSTypeParameterInstantiation(\n this: Printer,\n node: t.TSTypeParameterInstantiation,\n parent: t.Node,\n): void {\n this.token(\"<\");\n\n let printTrailingSeparator =\n parent.type === \"ArrowFunctionExpression\" && node.params.length === 1;\n if (this.tokenMap && node.start != null && node.end != null) {\n // Only force the trailing comma for pre-existing nodes if they\n // already had a comma (either because they were multi-param, or\n // because they had a trailing comma)\n printTrailingSeparator &&= !!this.tokenMap.find(node, t =>\n this.tokenMap.matchesOriginal(t, \",\"),\n );\n // Preseve the trailing comma if it was there before\n printTrailingSeparator ||= this.shouldPrintTrailingComma(\">\");\n }\n\n this.printList(node.params, { printTrailingSeparator });\n this.token(\">\");\n}\n\nexport { TSTypeParameterInstantiation as TSTypeParameterDeclaration };\n\nexport function TSTypeParameter(this: Printer, node: t.TSTypeParameter) {\n if (node.in) {\n this.word(\"in\");\n this.space();\n }\n\n if (node.out) {\n this.word(\"out\");\n this.space();\n }\n\n this.word(\n !process.env.BABEL_8_BREAKING\n ? (node.name as unknown as string)\n : (node.name as unknown as t.Identifier).name,\n );\n\n if (node.constraint) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.constraint);\n }\n\n if (node.default) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.default);\n }\n}\n\nexport function TSParameterProperty(\n this: Printer,\n node: t.TSParameterProperty,\n) {\n if (node.accessibility) {\n this.word(node.accessibility);\n this.space();\n }\n\n if (node.readonly) {\n this.word(\"readonly\");\n this.space();\n }\n\n this._param(node.parameter);\n}\n\nexport function TSDeclareFunction(\n this: Printer,\n node: t.TSDeclareFunction,\n parent: t.ParentMaps[\"TSDeclareFunction\"],\n) {\n if (node.declare) {\n this.word(\"declare\");\n this.space();\n }\n this._functionHead(node, parent);\n this.semicolon();\n}\n\nexport function TSDeclareMethod(this: Printer, node: t.TSDeclareMethod) {\n this._classMethodHead(node);\n this.semicolon();\n}\n\nexport function TSQualifiedName(this: Printer, node: t.TSQualifiedName) {\n this.print(node.left);\n this.token(\".\");\n this.print(node.right);\n}\n\nexport function TSCallSignatureDeclaration(\n this: Printer,\n node: t.TSCallSignatureDeclaration,\n) {\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nfunction maybePrintTrailingCommaOrSemicolon(printer: Printer, node: t.Node) {\n if (!printer.tokenMap || !node.start || !node.end) {\n printer.semicolon();\n return;\n }\n\n if (printer.tokenMap.endMatches(node, \",\")) {\n printer.token(\",\");\n } else if (printer.tokenMap.endMatches(node, \";\")) {\n printer.semicolon();\n }\n}\n\nexport function TSConstructSignatureDeclaration(\n this: Printer,\n node: t.TSConstructSignatureDeclaration,\n) {\n this.word(\"new\");\n this.space();\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSPropertySignature(\n this: Printer,\n node: t.TSPropertySignature,\n) {\n const { readonly } = node;\n if (readonly) {\n this.word(\"readonly\");\n this.space();\n }\n this.tsPrintPropertyOrMethodName(node);\n this.print(node.typeAnnotation);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function tsPrintPropertyOrMethodName(\n this: Printer,\n node: t.TSPropertySignature | t.TSMethodSignature,\n) {\n if (node.computed) {\n this.token(\"[\");\n }\n this.print(node.key);\n if (node.computed) {\n this.token(\"]\");\n }\n if (node.optional) {\n this.token(\"?\");\n }\n}\n\nexport function TSMethodSignature(this: Printer, node: t.TSMethodSignature) {\n const { kind } = node;\n if (kind === \"set\" || kind === \"get\") {\n this.word(kind);\n this.space();\n }\n this.tsPrintPropertyOrMethodName(node);\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSIndexSignature(this: Printer, node: t.TSIndexSignature) {\n const { readonly, static: isStatic } = node;\n if (isStatic) {\n this.word(\"static\");\n this.space();\n }\n if (readonly) {\n this.word(\"readonly\");\n this.space();\n }\n this.token(\"[\");\n this._parameters(node.parameters, \"]\");\n this.print(node.typeAnnotation);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSAnyKeyword(this: Printer) {\n this.word(\"any\");\n}\nexport function TSBigIntKeyword(this: Printer) {\n this.word(\"bigint\");\n}\nexport function TSUnknownKeyword(this: Printer) {\n this.word(\"unknown\");\n}\nexport function TSNumberKeyword(this: Printer) {\n this.word(\"number\");\n}\nexport function TSObjectKeyword(this: Printer) {\n this.word(\"object\");\n}\nexport function TSBooleanKeyword(this: Printer) {\n this.word(\"boolean\");\n}\nexport function TSStringKeyword(this: Printer) {\n this.word(\"string\");\n}\nexport function TSSymbolKeyword(this: Printer) {\n this.word(\"symbol\");\n}\nexport function TSVoidKeyword(this: Printer) {\n this.word(\"void\");\n}\nexport function TSUndefinedKeyword(this: Printer) {\n this.word(\"undefined\");\n}\nexport function TSNullKeyword(this: Printer) {\n this.word(\"null\");\n}\nexport function TSNeverKeyword(this: Printer) {\n this.word(\"never\");\n}\nexport function TSIntrinsicKeyword(this: Printer) {\n this.word(\"intrinsic\");\n}\n\nexport function TSThisType(this: Printer) {\n this.word(\"this\");\n}\n\nexport function TSFunctionType(this: Printer, node: t.TSFunctionType) {\n this.tsPrintFunctionOrConstructorType(node);\n}\n\nexport function TSConstructorType(this: Printer, node: t.TSConstructorType) {\n if (node.abstract) {\n this.word(\"abstract\");\n this.space();\n }\n this.word(\"new\");\n this.space();\n this.tsPrintFunctionOrConstructorType(node);\n}\n\nexport function tsPrintFunctionOrConstructorType(\n this: Printer,\n node: t.TSFunctionType | t.TSConstructorType,\n) {\n const { typeParameters } = node;\n const parameters = process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n node.params\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n node.parameters;\n this.print(typeParameters);\n this.token(\"(\");\n this._parameters(parameters, \")\");\n this.space();\n const returnType = process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n node.returnType\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n node.typeAnnotation;\n this.print(returnType);\n}\n\nexport function TSTypeReference(this: Printer, node: t.TSTypeReference) {\n this.print(node.typeName, !!node.typeParameters);\n this.print(node.typeParameters);\n}\n\nexport function TSTypePredicate(this: Printer, node: t.TSTypePredicate) {\n if (node.asserts) {\n this.word(\"asserts\");\n this.space();\n }\n this.print(node.parameterName);\n if (node.typeAnnotation) {\n this.space();\n this.word(\"is\");\n this.space();\n this.print(node.typeAnnotation.typeAnnotation);\n }\n}\n\nexport function TSTypeQuery(this: Printer, node: t.TSTypeQuery) {\n this.word(\"typeof\");\n this.space();\n this.print(node.exprName);\n\n if (node.typeParameters) {\n this.print(node.typeParameters);\n }\n}\n\nexport function TSTypeLiteral(this: Printer, node: t.TSTypeLiteral) {\n printBraced(this, node, () =>\n this.printJoin(node.members, { indent: true, statement: true }),\n );\n}\n\nexport function TSArrayType(this: Printer, node: t.TSArrayType) {\n this.print(node.elementType, true);\n\n this.token(\"[\");\n this.token(\"]\");\n}\n\nexport function TSTupleType(this: Printer, node: t.TSTupleType) {\n this.token(\"[\");\n this.printList(node.elementTypes, {\n printTrailingSeparator: this.shouldPrintTrailingComma(\"]\"),\n });\n this.token(\"]\");\n}\n\nexport function TSOptionalType(this: Printer, node: t.TSOptionalType) {\n this.print(node.typeAnnotation);\n this.token(\"?\");\n}\n\nexport function TSRestType(this: Printer, node: t.TSRestType) {\n this.token(\"...\");\n this.print(node.typeAnnotation);\n}\n\nexport function TSNamedTupleMember(this: Printer, node: t.TSNamedTupleMember) {\n this.print(node.label);\n if (node.optional) this.token(\"?\");\n this.token(\":\");\n this.space();\n this.print(node.elementType);\n}\n\nexport function TSUnionType(this: Printer, node: t.TSUnionType) {\n tsPrintUnionOrIntersectionType(this, node, \"|\");\n}\n\nexport function TSIntersectionType(this: Printer, node: t.TSIntersectionType) {\n tsPrintUnionOrIntersectionType(this, node, \"&\");\n}\n\nfunction tsPrintUnionOrIntersectionType(\n printer: Printer,\n node: t.TSUnionType | t.TSIntersectionType,\n sep: \"|\" | \"&\",\n) {\n let hasLeadingToken = 0;\n if (printer.tokenMap?.startMatches(node, sep)) {\n hasLeadingToken = 1;\n printer.token(sep);\n }\n\n printer.printJoin(node.types, {\n separator(i) {\n this.space();\n this.token(sep, null, i + hasLeadingToken);\n this.space();\n },\n });\n}\n\nexport function TSConditionalType(this: Printer, node: t.TSConditionalType) {\n this.print(node.checkType);\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.extendsType);\n this.space();\n this.token(\"?\");\n this.space();\n this.print(node.trueType);\n this.space();\n this.token(\":\");\n this.space();\n this.print(node.falseType);\n}\n\nexport function TSInferType(this: Printer, node: t.TSInferType) {\n this.word(\"infer\");\n this.print(node.typeParameter);\n}\n\nexport function TSParenthesizedType(\n this: Printer,\n node: t.TSParenthesizedType,\n) {\n this.token(\"(\");\n this.print(node.typeAnnotation);\n this.token(\")\");\n}\n\nexport function TSTypeOperator(this: Printer, node: t.TSTypeOperator) {\n this.word(node.operator);\n this.space();\n this.print(node.typeAnnotation);\n}\n\nexport function TSIndexedAccessType(\n this: Printer,\n node: t.TSIndexedAccessType,\n) {\n this.print(node.objectType, true);\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n\nexport function TSMappedType(this: Printer, node: t.TSMappedType) {\n const { nameType, optional, readonly, typeAnnotation } = node;\n this.token(\"{\");\n const exit = this.enterDelimited();\n this.space();\n if (readonly) {\n tokenIfPlusMinus(this, readonly);\n this.word(\"readonly\");\n this.space();\n }\n\n this.token(\"[\");\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n this.word(node.key.name);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n this.word(node.typeParameter.name);\n }\n\n this.space();\n this.word(\"in\");\n this.space();\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n this.print(node.constraint);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n this.print(node.typeParameter.constraint);\n }\n\n if (nameType) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(nameType);\n }\n\n this.token(\"]\");\n\n if (optional) {\n tokenIfPlusMinus(this, optional);\n this.token(\"?\");\n }\n\n if (typeAnnotation) {\n this.token(\":\");\n this.space();\n this.print(typeAnnotation);\n }\n this.space();\n exit();\n this.token(\"}\");\n}\n\nfunction tokenIfPlusMinus(self: Printer, tok: true | \"+\" | \"-\") {\n if (tok !== true) {\n self.token(tok);\n }\n}\n\nexport function TSLiteralType(this: Printer, node: t.TSLiteralType) {\n this.print(node.literal);\n}\n\nexport function TSClassImplements(\n this: Printer,\n // TODO(Babel 8): Just use t.TSClassImplements\n node: Extract<\n t.Node,\n { type: \"TSClassImplements\" | \"TSExpressionWithTypeArguments\" }\n >,\n) {\n this.print(node.expression);\n this.print(node.typeParameters);\n}\n\nexport {\n // TODO: Remove this in Babel 8\n TSClassImplements as TSExpressionWithTypeArguments,\n TSClassImplements as TSInterfaceHeritage,\n};\n\nexport function TSInterfaceDeclaration(\n this: Printer,\n node: t.TSInterfaceDeclaration,\n) {\n const { declare, id, typeParameters, extends: extendz, body } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"interface\");\n this.space();\n this.print(id);\n this.print(typeParameters);\n if (extendz?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(extendz);\n }\n this.space();\n this.print(body);\n}\n\nexport function TSInterfaceBody(this: Printer, node: t.TSInterfaceBody) {\n printBraced(this, node, () =>\n this.printJoin(node.body, { indent: true, statement: true }),\n );\n}\n\nexport function TSTypeAliasDeclaration(\n this: Printer,\n node: t.TSTypeAliasDeclaration,\n) {\n const { declare, id, typeParameters, typeAnnotation } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"type\");\n this.space();\n this.print(id);\n this.print(typeParameters);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(typeAnnotation);\n this.semicolon();\n}\n\nfunction TSTypeExpression(\n this: Printer,\n node: t.TSAsExpression | t.TSSatisfiesExpression,\n) {\n const { type, expression, typeAnnotation } = node;\n this.print(expression, true);\n this.space();\n this.word(type === \"TSAsExpression\" ? \"as\" : \"satisfies\");\n this.space();\n this.print(typeAnnotation);\n}\n\nexport {\n TSTypeExpression as TSAsExpression,\n TSTypeExpression as TSSatisfiesExpression,\n};\n\nexport function TSTypeAssertion(this: Printer, node: t.TSTypeAssertion) {\n const { typeAnnotation, expression } = node;\n this.token(\"<\");\n this.print(typeAnnotation);\n this.token(\">\");\n this.space();\n this.print(expression);\n}\n\nexport function TSInstantiationExpression(\n this: Printer,\n node: t.TSInstantiationExpression,\n) {\n this.print(node.expression);\n this.print(node.typeParameters);\n}\n\nexport function TSEnumDeclaration(this: Printer, node: t.TSEnumDeclaration) {\n const { declare, const: isConst, id, members } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n if (isConst) {\n this.word(\"const\");\n this.space();\n }\n this.word(\"enum\");\n this.space();\n this.print(id);\n this.space();\n\n printBraced(this, node, () =>\n this.printList(members, {\n indent: true,\n statement: true,\n // TODO: Default to false for consistency with everything else\n printTrailingSeparator: this.shouldPrintTrailingComma(\"}\") ?? true,\n }),\n );\n}\n\nexport function TSEnumMember(this: Printer, node: t.TSEnumMember) {\n const { id, initializer } = node;\n this.print(id);\n if (initializer) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(initializer);\n }\n}\n\nexport function TSModuleDeclaration(\n this: Printer,\n node: t.TSModuleDeclaration,\n) {\n const { declare, id, kind } = node;\n\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n\n if (!node.global) {\n this.word(kind ?? (id.type === \"Identifier\" ? \"namespace\" : \"module\"));\n this.space();\n }\n this.print(id);\n\n if (!node.body) {\n this.semicolon();\n return;\n }\n\n let body = node.body;\n while (body.type === \"TSModuleDeclaration\") {\n this.token(\".\");\n this.print(body.id);\n body = body.body;\n }\n\n this.space();\n this.print(body);\n}\n\nexport function TSModuleBlock(this: Printer, node: t.TSModuleBlock) {\n printBraced(this, node, () =>\n this.printSequence(node.body, { indent: true }),\n );\n}\n\nexport function TSImportType(this: Printer, node: t.TSImportType) {\n const { argument, qualifier, typeParameters } = node;\n this.word(\"import\");\n this.token(\"(\");\n this.print(argument);\n this.token(\")\");\n if (qualifier) {\n this.token(\".\");\n this.print(qualifier);\n }\n if (typeParameters) {\n this.print(typeParameters);\n }\n}\n\nexport function TSImportEqualsDeclaration(\n this: Printer,\n node: t.TSImportEqualsDeclaration,\n) {\n const { isExport, id, moduleReference } = node;\n if (isExport) {\n this.word(\"export\");\n this.space();\n }\n this.word(\"import\");\n this.space();\n this.print(id);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(moduleReference);\n this.semicolon();\n}\n\nexport function TSExternalModuleReference(\n this: Printer,\n node: t.TSExternalModuleReference,\n) {\n this.token(\"require(\");\n this.print(node.expression);\n this.token(\")\");\n}\n\nexport function TSNonNullExpression(\n this: Printer,\n node: t.TSNonNullExpression,\n) {\n this.print(node.expression);\n this.token(\"!\");\n}\n\nexport function TSExportAssignment(this: Printer, node: t.TSExportAssignment) {\n this.word(\"export\");\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.expression);\n this.semicolon();\n}\n\nexport function TSNamespaceExportDeclaration(\n this: Printer,\n node: t.TSNamespaceExportDeclaration,\n) {\n this.word(\"export\");\n this.space();\n this.word(\"as\");\n this.space();\n this.word(\"namespace\");\n this.space();\n this.print(node.id);\n this.semicolon();\n}\n\nexport function tsPrintSignatureDeclarationBase(this: Printer, node: any) {\n const { typeParameters } = node;\n const parameters = process.env.BABEL_8_BREAKING\n ? node.params\n : node.parameters;\n this.print(typeParameters);\n this.token(\"(\");\n this._parameters(parameters, \")\");\n const returnType = process.env.BABEL_8_BREAKING\n ? node.returnType\n : node.typeAnnotation;\n this.print(returnType);\n}\n\nexport function tsPrintClassMemberModifiers(\n this: Printer,\n node:\n | t.ClassProperty\n | t.ClassAccessorProperty\n | t.ClassMethod\n | t.ClassPrivateMethod\n | t.TSDeclareMethod,\n) {\n const isField =\n node.type === \"ClassAccessorProperty\" || node.type === \"ClassProperty\";\n printModifiersList(this, node, [\n isField && node.declare && \"declare\",\n node.accessibility,\n ]);\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n printModifiersList(this, node, [\n node.override && \"override\",\n node.abstract && \"abstract\",\n isField && node.readonly && \"readonly\",\n ]);\n}\n\nfunction printBraced(printer: Printer, node: t.Node, cb: () => void) {\n printer.token(\"{\");\n const exit = printer.enterDelimited();\n cb();\n exit();\n printer.rightBrace(node);\n}\n\nfunction printModifiersList(\n printer: Printer,\n node: t.Node,\n modifiers: (string | false | null)[],\n) {\n const modifiersSet = new Set<string>();\n for (const modifier of modifiers) {\n if (modifier) modifiersSet.add(modifier);\n }\n\n printer.tokenMap?.find(node, tok => {\n if (modifiersSet.has(tok.value)) {\n printer.token(tok.value);\n printer.space();\n modifiersSet.delete(tok.value);\n return modifiersSet.size === 0;\n }\n });\n\n for (const modifier of modifiersSet) {\n printer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EgI,GAAG,IAAI;IAClC,IAAI2C,YAAY,CAACI,GAAG,CAAC/C,GAAG,CAACgD,KAAK,CAAC,EAAE;MAC/BpI,OAAO,CAAC1C,KAAK,CAAC8H,GAAG,CAACgD,KAAK,CAAC;MACxBpI,OAAO,CAACvC,KAAK,CAAC,CAAC;MACfsK,YAAY,CAACM,MAAM,CAACjD,GAAG,CAACgD,KAAK,CAAC;MAC9B,OAAOL,YAAY,CAACO,IAAI,KAAK,CAAC;IAChC;EACF,CAAC,CAAC;EAEF,KAAK,MAAML,QAAQ,IAAIF,YAAY,EAAE;IACnC/H,OAAO,CAACtB,IAAI,CAACuJ,QAAQ,CAAC;IACtBjI,OAAO,CAACvC,KAAK,CAAC,CAAC;EACjB;AACF","ignoreList":[]}1 {"version":3,"names":["TSTypeAnnotation","node","parent","token","type","typeAnnotation","space","optional","print","TSTypeParameterInstantiation","printTrailingSeparator","params","length","tokenMap","start","end","find","t","matchesOriginal","shouldPrintTrailingComma","printList","TSTypeParameter","in","word","out","name","constraint","default","TSParameterProperty","accessibility","readonly","_param","parameter","TSDeclareFunction","declare","_functionHead","semicolon","TSDeclareMethod","_classMethodHead","TSQualifiedName","left","right","TSCallSignatureDeclaration","tsPrintSignatureDeclarationBase","maybePrintTrailingCommaOrSemicolon","printer","endMatches","TSConstructSignatureDeclaration","TSPropertySignature","tsPrintPropertyOrMethodName","computed","key","TSMethodSignature","kind","TSIndexSignature","static","isStatic","_parameters","parameters","TSAnyKeyword","TSBigIntKeyword","TSUnknownKeyword","TSNumberKeyword","TSObjectKeyword","TSBooleanKeyword","TSStringKeyword","TSSymbolKeyword","TSVoidKeyword","TSUndefinedKeyword","TSNullKeyword","TSNeverKeyword","TSIntrinsicKeyword","TSThisType","TSFunctionType","tsPrintFunctionOrConstructorType","TSConstructorType","abstract","typeParameters","returnType","TSTypeReference","typeArguments","typeName","TSTypePredicate","asserts","parameterName","TSTypeQuery","exprName","TSTypeLiteral","printBraced","printJoin","members","TSArrayType","elementType","TSTupleType","elementTypes","TSOptionalType","TSRestType","TSNamedTupleMember","label","TSUnionType","tsPrintUnionOrIntersectionType","TSIntersectionType","sep","_printer$tokenMap","hasLeadingToken","startMatches","types","undefined","i","TSConditionalType","checkType","extendsType","trueType","falseType","TSInferType","typeParameter","TSParenthesizedType","TSTypeOperator","operator","TSIndexedAccessType","objectType","indexType","TSMappedType","nameType","exit","enterDelimited","tokenIfPlusMinus","self","tok","TSLiteralType","literal","TSClassImplements","expression","TSInterfaceDeclaration","id","extends","extendz","body","TSInterfaceBody","TSTypeAliasDeclaration","TSTypeExpression","TSTypeAssertion","TSInstantiationExpression","TSEnumDeclaration","const","isConst","TSEnumBody","call","_this$shouldPrintTrai","TSEnumMember","initializer","TSModuleDeclaration","global","TSModuleBlock","printSequence","TSImportType","argument","qualifier","options","TSImportEqualsDeclaration","isExport","moduleReference","TSExternalModuleReference","TSNonNullExpression","TSExportAssignment","TSNamespaceExportDeclaration","tsPrintClassMemberModifiers","isField","printModifiersList","override","cb","rightBrace","modifiers","_printer$tokenMap2","modifiersSet","Set","modifier","add","has","value","delete","size"],"sources":["../../src/generators/typescript.ts"],"sourcesContent":["import type Printer from \"../printer.ts\";\nimport type * as t from \"@babel/types\";\n\nexport function TSTypeAnnotation(\n this: Printer,\n node: t.TSTypeAnnotation,\n parent: t.Node,\n) {\n // TODO(@nicolo-ribaudo): investigate not including => in the range\n // of the return type of an arrow function type\n this.token(\n (parent.type === \"TSFunctionType\" || parent.type === \"TSConstructorType\") &&\n (process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n parent.returnType\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n parent.typeAnnotation) === node\n ? \"=>\"\n : \":\",\n );\n this.space();\n // @ts-expect-error todo(flow->ts) can this be removed? `.optional` looks to be not existing property\n if (node.optional) this.token(\"?\");\n this.print(node.typeAnnotation);\n}\n\nexport function TSTypeParameterInstantiation(\n this: Printer,\n node: t.TSTypeParameterInstantiation,\n parent: t.Node,\n): void {\n this.token(\"<\");\n\n let printTrailingSeparator =\n parent.type === \"ArrowFunctionExpression\" && node.params.length === 1;\n if (this.tokenMap && node.start != null && node.end != null) {\n // Only force the trailing comma for pre-existing nodes if they\n // already had a comma (either because they were multi-param, or\n // because they had a trailing comma)\n printTrailingSeparator &&= !!this.tokenMap.find(node, t =>\n this.tokenMap.matchesOriginal(t, \",\"),\n );\n // Preseve the trailing comma if it was there before\n printTrailingSeparator ||= this.shouldPrintTrailingComma(\">\");\n }\n\n this.printList(node.params, printTrailingSeparator);\n this.token(\">\");\n}\n\nexport { TSTypeParameterInstantiation as TSTypeParameterDeclaration };\n\nexport function TSTypeParameter(this: Printer, node: t.TSTypeParameter) {\n if (node.in) {\n this.word(\"in\");\n this.space();\n }\n\n if (node.out) {\n this.word(\"out\");\n this.space();\n }\n\n this.word(\n !process.env.BABEL_8_BREAKING\n ? (node.name as unknown as string)\n : (node.name as unknown as t.Identifier).name,\n );\n\n if (node.constraint) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.constraint);\n }\n\n if (node.default) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.default);\n }\n}\n\nexport function TSParameterProperty(\n this: Printer,\n node: t.TSParameterProperty,\n) {\n if (node.accessibility) {\n this.word(node.accessibility);\n this.space();\n }\n\n if (node.readonly) {\n this.word(\"readonly\");\n this.space();\n }\n\n this._param(node.parameter);\n}\n\nexport function TSDeclareFunction(\n this: Printer,\n node: t.TSDeclareFunction,\n parent: t.ParentMaps[\"TSDeclareFunction\"],\n) {\n if (node.declare) {\n this.word(\"declare\");\n this.space();\n }\n this._functionHead(node, parent);\n this.semicolon();\n}\n\nexport function TSDeclareMethod(this: Printer, node: t.TSDeclareMethod) {\n this._classMethodHead(node);\n this.semicolon();\n}\n\nexport function TSQualifiedName(this: Printer, node: t.TSQualifiedName) {\n this.print(node.left);\n this.token(\".\");\n this.print(node.right);\n}\n\nexport function TSCallSignatureDeclaration(\n this: Printer,\n node: t.TSCallSignatureDeclaration,\n) {\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nfunction maybePrintTrailingCommaOrSemicolon(printer: Printer, node: t.Node) {\n if (!printer.tokenMap || !node.start || !node.end) {\n printer.semicolon();\n return;\n }\n\n if (printer.tokenMap.endMatches(node, \",\")) {\n printer.token(\",\");\n } else if (printer.tokenMap.endMatches(node, \";\")) {\n printer.semicolon();\n }\n}\n\nexport function TSConstructSignatureDeclaration(\n this: Printer,\n node: t.TSConstructSignatureDeclaration,\n) {\n this.word(\"new\");\n this.space();\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSPropertySignature(\n this: Printer,\n node: t.TSPropertySignature,\n) {\n const { readonly } = node;\n if (readonly) {\n this.word(\"readonly\");\n this.space();\n }\n this.tsPrintPropertyOrMethodName(node);\n this.print(node.typeAnnotation);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function tsPrintPropertyOrMethodName(\n this: Printer,\n node: t.TSPropertySignature | t.TSMethodSignature,\n) {\n if (node.computed) {\n this.token(\"[\");\n }\n this.print(node.key);\n if (node.computed) {\n this.token(\"]\");\n }\n if (node.optional) {\n this.token(\"?\");\n }\n}\n\nexport function TSMethodSignature(this: Printer, node: t.TSMethodSignature) {\n const { kind } = node;\n if (kind === \"set\" || kind === \"get\") {\n this.word(kind);\n this.space();\n }\n this.tsPrintPropertyOrMethodName(node);\n this.tsPrintSignatureDeclarationBase(node);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSIndexSignature(this: Printer, node: t.TSIndexSignature) {\n const { readonly, static: isStatic } = node;\n if (isStatic) {\n this.word(\"static\");\n this.space();\n }\n if (readonly) {\n this.word(\"readonly\");\n this.space();\n }\n this.token(\"[\");\n this._parameters(node.parameters, \"]\");\n this.print(node.typeAnnotation);\n maybePrintTrailingCommaOrSemicolon(this, node);\n}\n\nexport function TSAnyKeyword(this: Printer) {\n this.word(\"any\");\n}\nexport function TSBigIntKeyword(this: Printer) {\n this.word(\"bigint\");\n}\nexport function TSUnknownKeyword(this: Printer) {\n this.word(\"unknown\");\n}\nexport function TSNumberKeyword(this: Printer) {\n this.word(\"number\");\n}\nexport function TSObjectKeyword(this: Printer) {\n this.word(\"object\");\n}\nexport function TSBooleanKeyword(this: Printer) {\n this.word(\"boolean\");\n}\nexport function TSStringKeyword(this: Printer) {\n this.word(\"string\");\n}\nexport function TSSymbolKeyword(this: Printer) {\n this.word(\"symbol\");\n}\nexport function TSVoidKeyword(this: Printer) {\n this.word(\"void\");\n}\nexport function TSUndefinedKeyword(this: Printer) {\n this.word(\"undefined\");\n}\nexport function TSNullKeyword(this: Printer) {\n this.word(\"null\");\n}\nexport function TSNeverKeyword(this: Printer) {\n this.word(\"never\");\n}\nexport function TSIntrinsicKeyword(this: Printer) {\n this.word(\"intrinsic\");\n}\n\nexport function TSThisType(this: Printer) {\n this.word(\"this\");\n}\n\nexport function TSFunctionType(this: Printer, node: t.TSFunctionType) {\n this.tsPrintFunctionOrConstructorType(node);\n}\n\nexport function TSConstructorType(this: Printer, node: t.TSConstructorType) {\n if (node.abstract) {\n this.word(\"abstract\");\n this.space();\n }\n this.word(\"new\");\n this.space();\n this.tsPrintFunctionOrConstructorType(node);\n}\n\nexport function tsPrintFunctionOrConstructorType(\n this: Printer,\n node: t.TSFunctionType | t.TSConstructorType,\n) {\n const { typeParameters } = node;\n const parameters = process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n node.params\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n node.parameters;\n this.print(typeParameters);\n this.token(\"(\");\n this._parameters(parameters, \")\");\n this.space();\n const returnType = process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n node.returnType\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n node.typeAnnotation;\n this.print(returnType);\n}\n\nexport function TSTypeReference(this: Printer, node: t.TSTypeReference) {\n const typeArguments = process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n node.typeArguments\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n node.typeParameters;\n this.print(node.typeName, !!typeArguments);\n this.print(typeArguments);\n}\n\nexport function TSTypePredicate(this: Printer, node: t.TSTypePredicate) {\n if (node.asserts) {\n this.word(\"asserts\");\n this.space();\n }\n this.print(node.parameterName);\n if (node.typeAnnotation) {\n this.space();\n this.word(\"is\");\n this.space();\n this.print(node.typeAnnotation.typeAnnotation);\n }\n}\n\nexport function TSTypeQuery(this: Printer, node: t.TSTypeQuery) {\n this.word(\"typeof\");\n this.space();\n this.print(node.exprName);\n\n const typeArguments = process.env.BABEL_8_BREAKING\n ? //@ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n node.typeArguments\n : //@ts-ignore(Babel 7 vs Babel 8) Babel 7 AST\n node.typeParameters;\n if (typeArguments) {\n this.print(typeArguments);\n }\n}\n\nexport function TSTypeLiteral(this: Printer, node: t.TSTypeLiteral) {\n printBraced(this, node, () => this.printJoin(node.members, true, true));\n}\n\nexport function TSArrayType(this: Printer, node: t.TSArrayType) {\n this.print(node.elementType, true);\n\n this.token(\"[\");\n this.token(\"]\");\n}\n\nexport function TSTupleType(this: Printer, node: t.TSTupleType) {\n this.token(\"[\");\n this.printList(node.elementTypes, this.shouldPrintTrailingComma(\"]\"));\n this.token(\"]\");\n}\n\nexport function TSOptionalType(this: Printer, node: t.TSOptionalType) {\n this.print(node.typeAnnotation);\n this.token(\"?\");\n}\n\nexport function TSRestType(this: Printer, node: t.TSRestType) {\n this.token(\"...\");\n this.print(node.typeAnnotation);\n}\n\nexport function TSNamedTupleMember(this: Printer, node: t.TSNamedTupleMember) {\n this.print(node.label);\n if (node.optional) this.token(\"?\");\n this.token(\":\");\n this.space();\n this.print(node.elementType);\n}\n\nexport function TSUnionType(this: Printer, node: t.TSUnionType) {\n tsPrintUnionOrIntersectionType(this, node, \"|\");\n}\n\nexport function TSIntersectionType(this: Printer, node: t.TSIntersectionType) {\n tsPrintUnionOrIntersectionType(this, node, \"&\");\n}\n\nfunction tsPrintUnionOrIntersectionType(\n printer: Printer,\n node: t.TSUnionType | t.TSIntersectionType,\n sep: \"|\" | \"&\",\n) {\n let hasLeadingToken = 0;\n if (printer.tokenMap?.startMatches(node, sep)) {\n hasLeadingToken = 1;\n printer.token(sep);\n }\n\n printer.printJoin(node.types, undefined, undefined, function (i) {\n this.space();\n this.token(sep, null, i + hasLeadingToken);\n this.space();\n });\n}\n\nexport function TSConditionalType(this: Printer, node: t.TSConditionalType) {\n this.print(node.checkType);\n this.space();\n this.word(\"extends\");\n this.space();\n this.print(node.extendsType);\n this.space();\n this.token(\"?\");\n this.space();\n this.print(node.trueType);\n this.space();\n this.token(\":\");\n this.space();\n this.print(node.falseType);\n}\n\nexport function TSInferType(this: Printer, node: t.TSInferType) {\n this.word(\"infer\");\n this.print(node.typeParameter);\n}\n\nexport function TSParenthesizedType(\n this: Printer,\n node: t.TSParenthesizedType,\n) {\n this.token(\"(\");\n this.print(node.typeAnnotation);\n this.token(\")\");\n}\n\nexport function TSTypeOperator(this: Printer, node: t.TSTypeOperator) {\n this.word(node.operator);\n this.space();\n this.print(node.typeAnnotation);\n}\n\nexport function TSIndexedAccessType(\n this: Printer,\n node: t.TSIndexedAccessType,\n) {\n this.print(node.objectType, true);\n this.token(\"[\");\n this.print(node.indexType);\n this.token(\"]\");\n}\n\nexport function TSMappedType(this: Printer, node: t.TSMappedType) {\n const { nameType, optional, readonly, typeAnnotation } = node;\n this.token(\"{\");\n const exit = this.enterDelimited();\n this.space();\n if (readonly) {\n tokenIfPlusMinus(this, readonly);\n this.word(\"readonly\");\n this.space();\n }\n\n this.token(\"[\");\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n this.word(node.key.name);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n this.word(node.typeParameter.name);\n }\n\n this.space();\n this.word(\"in\");\n this.space();\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST shape\n this.print(node.constraint);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n this.print(node.typeParameter.constraint);\n }\n\n if (nameType) {\n this.space();\n this.word(\"as\");\n this.space();\n this.print(nameType);\n }\n\n this.token(\"]\");\n\n if (optional) {\n tokenIfPlusMinus(this, optional);\n this.token(\"?\");\n }\n\n if (typeAnnotation) {\n this.token(\":\");\n this.space();\n this.print(typeAnnotation);\n }\n this.space();\n exit();\n this.token(\"}\");\n}\n\nfunction tokenIfPlusMinus(self: Printer, tok: true | \"+\" | \"-\") {\n if (tok !== true) {\n self.token(tok);\n }\n}\n\nexport function TSLiteralType(this: Printer, node: t.TSLiteralType) {\n this.print(node.literal);\n}\n\nexport function TSClassImplements(\n this: Printer,\n // TODO(Babel 8): Just use t.TSClassImplements\n node: t.Node & {\n expression: t.TSEntityName;\n typeArguments?: t.TSTypeParameterInstantiation;\n },\n) {\n this.print(node.expression);\n this.print(node.typeArguments);\n}\n\nexport { TSClassImplements as TSInterfaceHeritage };\n\nexport function TSInterfaceDeclaration(\n this: Printer,\n node: t.TSInterfaceDeclaration,\n) {\n const { declare, id, typeParameters, extends: extendz, body } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"interface\");\n this.space();\n this.print(id);\n this.print(typeParameters);\n if (extendz?.length) {\n this.space();\n this.word(\"extends\");\n this.space();\n this.printList(extendz);\n }\n this.space();\n this.print(body);\n}\n\nexport function TSInterfaceBody(this: Printer, node: t.TSInterfaceBody) {\n printBraced(this, node, () => this.printJoin(node.body, true, true));\n}\n\nexport function TSTypeAliasDeclaration(\n this: Printer,\n node: t.TSTypeAliasDeclaration,\n) {\n const { declare, id, typeParameters, typeAnnotation } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n this.word(\"type\");\n this.space();\n this.print(id);\n this.print(typeParameters);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(typeAnnotation);\n this.semicolon();\n}\n\nfunction TSTypeExpression(\n this: Printer,\n node: t.TSAsExpression | t.TSSatisfiesExpression,\n) {\n const { type, expression, typeAnnotation } = node;\n this.print(expression, true);\n this.space();\n this.word(type === \"TSAsExpression\" ? \"as\" : \"satisfies\");\n this.space();\n this.print(typeAnnotation);\n}\n\nexport {\n TSTypeExpression as TSAsExpression,\n TSTypeExpression as TSSatisfiesExpression,\n};\n\nexport function TSTypeAssertion(this: Printer, node: t.TSTypeAssertion) {\n const { typeAnnotation, expression } = node;\n this.token(\"<\");\n this.print(typeAnnotation);\n this.token(\">\");\n this.space();\n this.print(expression);\n}\n\nexport function TSInstantiationExpression(\n this: Printer,\n node: t.TSInstantiationExpression,\n) {\n this.print(node.expression);\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n this.print(node.typeArguments);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Removed in Babel 8\n this.print(node.typeParameters);\n }\n}\n\nexport function TSEnumDeclaration(this: Printer, node: t.TSEnumDeclaration) {\n const { declare, const: isConst, id } = node;\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n if (isConst) {\n this.word(\"const\");\n this.space();\n }\n this.word(\"enum\");\n this.space();\n this.print(id);\n this.space();\n\n if (process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n this.print(node.body);\n } else {\n // cast to TSEnumBody for Babel 7 AST\n TSEnumBody.call(this, node as unknown as t.TSEnumBody);\n }\n}\n\nexport function TSEnumBody(this: Printer, node: t.TSEnumBody) {\n printBraced(this, node, () =>\n this.printList(\n node.members,\n this.shouldPrintTrailingComma(\"}\") ??\n (process.env.BABEL_8_BREAKING ? false : true),\n true,\n true,\n ),\n );\n}\n\nexport function TSEnumMember(this: Printer, node: t.TSEnumMember) {\n const { id, initializer } = node;\n this.print(id);\n if (initializer) {\n this.space();\n this.token(\"=\");\n this.space();\n this.print(initializer);\n }\n}\n\nexport function TSModuleDeclaration(\n this: Printer,\n node: t.TSModuleDeclaration,\n) {\n const { declare, id, kind } = node;\n\n if (declare) {\n this.word(\"declare\");\n this.space();\n }\n\n if (process.env.BABEL_8_BREAKING) {\n if (kind !== \"global\") {\n this.word(kind);\n this.space();\n }\n\n this.print(node.id);\n if (!node.body) {\n this.semicolon();\n return;\n }\n this.space();\n this.print(node.body);\n } else {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n if (!node.global) {\n this.word(kind ?? (id.type === \"Identifier\" ? \"namespace\" : \"module\"));\n this.space();\n }\n\n this.print(id);\n\n if (!node.body) {\n this.semicolon();\n return;\n }\n\n let body = node.body;\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n while (body.type === \"TSModuleDeclaration\") {\n this.token(\".\");\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n this.print(body.id);\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST shape\n body = body.body;\n }\n\n this.space();\n this.print(body);\n }\n}\n\nexport function TSModuleBlock(this: Printer, node: t.TSModuleBlock) {\n printBraced(this, node, () => this.printSequence(node.body, true));\n}\n\nexport function TSImportType(this: Printer, node: t.TSImportType) {\n const { argument, qualifier, options } = node;\n this.word(\"import\");\n this.token(\"(\");\n this.print(argument);\n if (options) {\n this.token(\",\");\n this.print(options);\n }\n this.token(\")\");\n if (qualifier) {\n this.token(\".\");\n this.print(qualifier);\n }\n const typeArguments = process.env.BABEL_8_BREAKING\n ? //@ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n node.typeArguments\n : //@ts-ignore(Babel 7 vs Babel 8) Babel 7 AST\n node.typeParameters;\n if (typeArguments) {\n this.print(typeArguments);\n }\n}\n\nexport function TSImportEqualsDeclaration(\n this: Printer,\n node: t.TSImportEqualsDeclaration,\n) {\n const { isExport, id, moduleReference } = node;\n if (isExport) {\n this.word(\"export\");\n this.space();\n }\n this.word(\"import\");\n this.space();\n this.print(id);\n this.space();\n this.token(\"=\");\n this.space();\n this.print(moduleReference);\n this.semicolon();\n}\n\nexport function TSExternalModuleReference(\n this: Printer,\n node: t.TSExternalModuleReference,\n) {\n this.token(\"require(\");\n this.print(node.expression);\n this.token(\")\");\n}\n\nexport function TSNonNullExpression(\n this: Printer,\n node: t.TSNonNullExpression,\n) {\n this.print(node.expression);\n this.token(\"!\");\n}\n\nexport function TSExportAssignment(this: Printer, node: t.TSExportAssignment) {\n this.word(\"export\");\n this.space();\n this.token(\"=\");\n this.space();\n this.print(node.expression);\n this.semicolon();\n}\n\nexport function TSNamespaceExportDeclaration(\n this: Printer,\n node: t.TSNamespaceExportDeclaration,\n) {\n this.word(\"export\");\n this.space();\n this.word(\"as\");\n this.space();\n this.word(\"namespace\");\n this.space();\n this.print(node.id);\n this.semicolon();\n}\n\nexport function tsPrintSignatureDeclarationBase(this: Printer, node: any) {\n const { typeParameters } = node;\n const parameters = process.env.BABEL_8_BREAKING\n ? node.params\n : node.parameters;\n this.print(typeParameters);\n this.token(\"(\");\n this._parameters(parameters, \")\");\n const returnType = process.env.BABEL_8_BREAKING\n ? node.returnType\n : node.typeAnnotation;\n this.print(returnType);\n}\n\nexport function tsPrintClassMemberModifiers(\n this: Printer,\n node:\n | t.ClassProperty\n | t.ClassAccessorProperty\n | t.ClassMethod\n | t.ClassPrivateMethod\n | t.TSDeclareMethod,\n) {\n const isField =\n node.type === \"ClassAccessorProperty\" || node.type === \"ClassProperty\";\n printModifiersList(this, node, [\n isField && node.declare && \"declare\",\n node.accessibility,\n ]);\n if (node.static) {\n this.word(\"static\");\n this.space();\n }\n printModifiersList(this, node, [\n node.override && \"override\",\n node.abstract && \"abstract\",\n isField && node.readonly && \"readonly\",\n ]);\n}\n\nfunction printBraced(printer: Printer, node: t.Node, cb: () => void) {\n printer.token(\"{\");\n const exit = printer.enterDelimited();\n cb();\n exit();\n printer.rightBrace(node);\n}\n\nfunction printModifiersList(\n printer: Printer,\n node: t.Node,\n modifiers: (string | false | null)[],\n) {\n const modifiersSet = new Set<string>();\n for (const modifier of modifiers) {\n if (modifier) modifiersSet.add(modifier);\n }\n\n printer.tokenMap?.find(node, tok => {\n if (modifiersSet.has(tok.value)) {\n printer.token(tok.value);\n printer.space();\n modifiersSet.delete(tok.value);\n return modifiersSet.size === 0;\n }\n });\n\n for (const modifier of modifiersSet) {\n printer.word(modifier);\n printer.space();\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAGO,SAASA,gBAAgBA,CAE9BC,IAAwB,EACxBC,MAAc,EACd;EAGA,IAAI,CAACC,KAAK,CACR,CAACD,MAAM,CAACE,IAAI,KAAK,gBAAgB,IAAIF,MAAM,CAACE,IAAI,KAAK,mBAAmB,KAKlEF,MAAM,CAACG,cAAc,KAAMJ,IAAI,GACjC,IAAI,GACJ,GACN,CAAC;EACD,IAAI,CAACK,KAAK,CAAC,CAAC;EAEZ,IAAIL,IAAI,CAACM,QAAQ,EAAE,IAAI,CAACJ,SAAK,GAAI,CAAC;EAClC,IAAI,CAACK,KAAK,CAACP,IAAI,CAACI,cAAc,CAAC;AACjC;AAEO,SAASI,4BAA4BA,CAE1CR,IAAoC,EACpCC,MAAc,EACR;EACN,IAAI,CAACC,SAAK,GAAI,CAAC;EAEf,IAAIO,sBAAsB,GACxBR,MAAM,CAACE,IAAI,KAAK,yBAAyB,IAAIH,IAAI,CAACU,MAAM,CAACC,MAAM,KAAK,CAAC;EACvE,IAAI,IAAI,CAACC,QAAQ,IAAIZ,IAAI,CAACa,KAAK,IAAI,IAAI,IAAIb,IAAI,CAACc,GAAG,IAAI,IAAI,EAAE;IAI3DL,sBAAsB,KAAtBA,sBAAsB,GAAK,CA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AMyH,IAAI,GAAG/E,OAAO,CAACgF,cAAc,CAAC,CAAC;EACrC6C,EAAE,CAAC,CAAC;EACJ9C,IAAI,CAAC,CAAC;EACN/E,OAAO,CAAC8H,UAAU,CAAC1K,IAAI,CAAC;AAC1B;AAEA,SAASuK,kBAAkBA,CACzB3H,OAAgB,EAChB5C,IAAY,EACZ2K,SAAoC,EACpC;EAAA,IAAAC,kBAAA;EACA,MAAMC,YAAY,GAAG,IAAIC,GAAG,CAAS,CAAC;EACtC,KAAK,MAAMC,QAAQ,IAAIJ,SAAS,EAAE;IAChC,IAAII,QAAQ,EAAEF,YAAY,CAACG,GAAG,CAACD,QAAQ,CAAC;EAC1C;EAEA,CAAAH,kBAAA,GAAAhI,OAAO,CAAChC,QAAQ,aAAhBgK,kBAAA,CAAkB7J,IAAI,CAACf,IAAI,EAAE+H,GAAG,IAAI;IAClC,IAAI8C,YAAY,CAACI,GAAG,CAAClD,GAAG,CAACmD,KAAK,CAAC,EAAE;MAC/BtI,OAAO,CAAC1C,KAAK,CAAC6H,GAAG,CAACmD,KAAK,CAAC;MACxBtI,OAAO,CAACvC,KAAK,CAAC,CAAC;MACfwK,YAAY,CAACM,MAAM,CAACpD,GAAG,CAACmD,KAAK,CAAC;MAC9B,OAAOL,YAAY,CAACO,IAAI,KAAK,CAAC;IAChC;EACF,CAAC,CAAC;EAEF,KAAK,MAAML,QAAQ,IAAIF,YAAY,EAAE;IACnCjI,OAAO,CAACtB,IAAI,CAACyJ,QAAQ,CAAC;IACtBnI,OAAO,CAACvC,KAAK,CAAC,CAAC;EACjB;AACF","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/node/parentheses.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_t","require","_index","isArrayTypeAnnotation","isBinaryExpression","isCallExpression","isForOfStatement","isIndexedAccessType","isMemberExpression","isObjectPattern","isOptionalMemberExpression","isYieldExpression","isStatement","PRECEDENCE","Map","getBinaryPrecedence","node","nodeType","get","operator","isTSTypeExpression","isClassExtendsClause","parent","parentType","type","superClass","hasPostfixPart","object","callee","tag","NullableTypeAnnotation","FunctionTypeAnnotation","tokenContext","Boolean","TokenContext","arrowFlowReturnType","UpdateExpression","needsParenBeforeExpressionBrace","expressionStatement","arrowBody","ObjectExpression","DoExpression","async","Binary","left","parentPos","nodePos","right","undefined","UnionTypeAnnotation","OptionalIndexedAccessType","objectType","TSAsExpression","TSUnionType","TSInferType","TSInstantiationExpression","typeParameters","BinaryExpression","inForStatementInit","SequenceExpression","property","YieldExpression","test","ClassExpression","exportDefault","UnaryLike","FunctionExpression","ConditionalExpression","OptionalMemberExpression","AssignmentExpression","LogicalExpression","Identifier","_inForInit","getRawIdentifier","_node$extra","extra","parenthesized","rightType","id","name","isFollowedByBracket","computed","optional","forHead","forInHead","forOfHead","await"],"sources":["../../src/node/parentheses.ts"],"sourcesContent":["import {\n isArrayTypeAnnotation,\n isBinaryExpression,\n isCallExpression,\n isForOfStatement,\n isIndexedAccessType,\n isMemberExpression,\n isObjectPattern,\n isOptionalMemberExpression,\n isYieldExpression,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\nimport { TokenContext } from \"./index.ts\";\n\nconst PRECEDENCE = new Map([\n [\"||\", 0],\n [\"??\", 0],\n [\"|>\", 0],\n [\"&&\", 1],\n [\"|\", 2],\n [\"^\", 3],\n [\"&\", 4],\n [\"==\", 5],\n [\"===\", 5],\n [\"!=\", 5],\n [\"!==\", 5],\n [\"<\", 6],\n [\">\", 6],\n [\"<=\", 6],\n [\">=\", 6],\n [\"in\", 6],\n [\"instanceof\", 6],\n [\">>\", 7],\n [\"<<\", 7],\n [\">>>\", 7],\n [\"+\", 8],\n [\"-\", 8],\n [\"*\", 9],\n [\"/\", 9],\n [\"%\", 9],\n [\"**\", 10],\n]);\n\nfunction getBinaryPrecedence(\n node: t.Binary | t.TSAsExpression | t.TSSatisfiesExpression,\n nodeType: string,\n): number;\nfunction getBinaryPrecedence(\n node: t.Node,\n nodeType: string,\n): number | undefined;\nfunction getBinaryPrecedence(node: t.Node, nodeType: string) {\n if (nodeType === \"BinaryExpression\" || nodeType === \"LogicalExpression\") {\n return PRECEDENCE.get((node as t.Binary).operator);\n }\n if (nodeType === \"TSAsExpression\" || nodeType === \"TSSatisfiesExpression\") {\n return PRECEDENCE.get(\"in\");\n }\n}\n\nfunction isTSTypeExpression(nodeType: string) {\n return (\n nodeType === \"TSAsExpression\" ||\n nodeType === \"TSSatisfiesExpression\" ||\n nodeType === \"TSTypeAssertion\"\n );\n}\n\nconst isClassExtendsClause = (\n node: t.Node,\n parent: t.Node,\n): parent is t.Class => {\n const parentType = parent.type;\n return (\n (parentType === \"ClassDeclaration\" || parentType === \"ClassExpression\") &&\n parent.superClass === node\n );\n};\n\nconst hasPostfixPart = (node: t.Node, parent: t.Node) => {\n const parentType = parent.type;\n return (\n ((parentType === \"MemberExpression\" ||\n parentType === \"OptionalMemberExpression\") &&\n parent.object === node) ||\n ((parentType === \"CallExpression\" ||\n parentType === \"OptionalCallExpression\" ||\n parentType === \"NewExpression\") &&\n parent.callee === node) ||\n (parentType === \"TaggedTemplateExpression\" && parent.tag === node) ||\n parentType === \"TSNonNullExpression\"\n );\n};\n\nexport function NullableTypeAnnotation(\n node: t.NullableTypeAnnotation,\n parent: t.Node,\n): boolean {\n return isArrayTypeAnnotation(parent);\n}\n\nexport function FunctionTypeAnnotation(\n node: t.FunctionTypeAnnotation,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n const parentType = parent.type;\n return (\n // (() => A) | (() => B)\n parentType === \"UnionTypeAnnotation\" ||\n // (() => A) & (() => B)\n parentType === \"IntersectionTypeAnnotation\" ||\n // (() => A)[]\n parentType === \"ArrayTypeAnnotation\" ||\n Boolean(tokenContext & TokenContext.arrowFlowReturnType)\n );\n}\n\nexport function UpdateExpression(\n node: t.UpdateExpression,\n parent: t.Node,\n): boolean {\n return hasPostfixPart(node, parent) || isClassExtendsClause(node, parent);\n}\n\nfunction needsParenBeforeExpressionBrace(tokenContext: number) {\n return Boolean(\n tokenContext & (TokenContext.expressionStatement | TokenContext.arrowBody),\n );\n}\n\nexport function ObjectExpression(\n node: t.ObjectExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return needsParenBeforeExpressionBrace(tokenContext);\n}\n\nexport function DoExpression(\n node: t.DoExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n // `async do` can start an expression statement\n return (\n !node.async && Boolean(tokenContext & TokenContext.expressionStatement)\n );\n}\n\nexport function Binary(\n node: t.Binary | t.TSAsExpression | t.TSSatisfiesExpression,\n parent: t.Node,\n): boolean | undefined {\n const parentType = parent.type;\n if (\n node.type === \"BinaryExpression\" &&\n node.operator === \"**\" &&\n parentType === \"BinaryExpression\" &&\n parent.operator === \"**\"\n ) {\n return parent.left === node;\n }\n\n if (isClassExtendsClause(node, parent)) {\n return true;\n }\n\n if (\n hasPostfixPart(node, parent) ||\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n parentType === \"AwaitExpression\"\n ) {\n return true;\n }\n\n const parentPos = getBinaryPrecedence(parent, parentType);\n if (parentPos != null) {\n const nodePos = getBinaryPrecedence(node, node.type);\n if (\n // Logical expressions with the same precedence don't need parens.\n (parentPos === nodePos &&\n parentType === \"BinaryExpression\" &&\n parent.right === node) ||\n parentPos > nodePos\n ) {\n return true;\n }\n }\n\n return undefined;\n}\n\nexport function UnionTypeAnnotation(\n node: t.UnionTypeAnnotation,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n return (\n parentType === \"ArrayTypeAnnotation\" ||\n parentType === \"NullableTypeAnnotation\" ||\n parentType === \"IntersectionTypeAnnotation\" ||\n parentType === \"UnionTypeAnnotation\"\n );\n}\n\nexport { UnionTypeAnnotation as IntersectionTypeAnnotation };\n\nexport function OptionalIndexedAccessType(\n node: t.OptionalIndexedAccessType,\n parent: t.Node,\n): boolean {\n return isIndexedAccessType(parent) && parent.objectType === node;\n}\n\nexport function TSAsExpression(\n node: t.TSAsExpression | t.TSSatisfiesExpression,\n parent: t.Node,\n): boolean {\n if (\n (parent.type === \"AssignmentExpression\" ||\n parent.type === \"AssignmentPattern\") &&\n parent.left === node\n ) {\n return true;\n }\n if (\n parent.type === \"BinaryExpression\" &&\n (parent.operator === \"|\" || parent.operator === \"&\") &&\n node === parent.left\n ) {\n return true;\n }\n return Binary(node, parent);\n}\n\nexport { TSAsExpression as TSSatisfiesExpression };\n\nexport { UnaryLike as TSTypeAssertion };\n\nexport function TSUnionType(node: t.TSUnionType, parent: t.Node): boolean {\n const parentType = parent.type;\n return (\n parentType === \"TSArrayType\" ||\n parentType === \"TSOptionalType\" ||\n parentType === \"TSIntersectionType\" ||\n parentType === \"TSRestType\"\n );\n}\n\nexport { TSUnionType as TSIntersectionType };\n\nexport function TSInferType(node: t.TSInferType, parent: t.Node): boolean {\n const parentType = parent.type;\n return parentType === \"TSArrayType\" || parentType === \"TSOptionalType\";\n}\n\nexport function TSInstantiationExpression(\n node: t.TSInstantiationExpression,\n parent: t.Node,\n) {\n const parentType = parent.type;\n return (\n (parentType === \"CallExpression\" ||\n parentType === \"OptionalCallExpression\" ||\n parentType === \"NewExpression\" ||\n parentType === \"TSInstantiationExpression\") &&\n !! parent.typeParameters\n );\n}\n\nexport function BinaryExpression(\n node: t.BinaryExpression,\n parent: t.Node,\n tokenContext: unknown,\n inForStatementInit: boolean,\n): boolean {\n // for ((1 in []);;);\n // for (var x = (1 in []) in 2);\n return node.operator === \"in\" && inForStatementInit;\n}\n\nexport function SequenceExpression(\n node: t.SequenceExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n if (\n parentType === \"SequenceExpression\" ||\n parentType === \"ParenthesizedExpression\" ||\n (parentType === \"MemberExpression\" && parent.property === node) ||\n (parentType === \"OptionalMemberExpression\" && parent.property === node) ||\n parentType === \"TemplateLiteral\"\n ) {\n return false;\n }\n if (parentType === \"ClassDeclaration\") {\n return true;\n }\n if (parentType === \"ForOfStatement\") {\n return parent.right === node;\n }\n if (parentType === \"ExportDefaultDeclaration\") {\n return true;\n }\n\n return !isStatement(parent);\n}\n\nexport function YieldExpression(\n node: t.YieldExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n return (\n parentType === \"BinaryExpression\" ||\n parentType === \"LogicalExpression\" ||\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n hasPostfixPart(node, parent) ||\n (parentType === \"AwaitExpression\" && isYieldExpression(node)) ||\n (parentType === \"ConditionalExpression\" && node === parent.test) ||\n isClassExtendsClause(node, parent) ||\n isTSTypeExpression(parentType)\n );\n}\n\nexport { YieldExpression as AwaitExpression };\n\nexport function ClassExpression(\n node: t.ClassExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return Boolean(\n tokenContext &\n (TokenContext.expressionStatement | TokenContext.exportDefault),\n );\n}\n\nexport function UnaryLike(\n node:\n | t.UnaryLike\n | t.TSTypeAssertion\n | t.ArrowFunctionExpression\n | t.ConditionalExpression\n | t.AssignmentExpression,\n parent: t.Node,\n): boolean {\n return (\n hasPostfixPart(node, parent) ||\n (isBinaryExpression(parent) &&\n parent.operator === \"**\" &&\n parent.left === node) ||\n isClassExtendsClause(node, parent)\n );\n}\n\nexport function FunctionExpression(\n node: t.FunctionExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return Boolean(\n tokenContext &\n (TokenContext.expressionStatement | TokenContext.exportDefault),\n );\n}\n\nexport function ConditionalExpression(\n node:\n | t.ConditionalExpression\n | t.ArrowFunctionExpression\n | t.AssignmentExpression,\n parent?: t.Node,\n): boolean {\n const parentType = parent.type;\n if (\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n parentType === \"BinaryExpression\" ||\n parentType === \"LogicalExpression\" ||\n (parentType === \"ConditionalExpression\" && parent.test === node) ||\n parentType === \"AwaitExpression\" ||\n isTSTypeExpression(parentType)\n ) {\n return true;\n }\n\n return UnaryLike(node, parent);\n}\n\nexport { ConditionalExpression as ArrowFunctionExpression };\n\nexport function OptionalMemberExpression(\n node: t.OptionalMemberExpression,\n parent: t.Node,\n): boolean {\n return (\n (isCallExpression(parent) && parent.callee === node) ||\n (isMemberExpression(parent) && parent.object === node)\n );\n}\n\nexport { OptionalMemberExpression as OptionalCallExpression };\n\nexport function AssignmentExpression(\n node: t.AssignmentExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n if (\n needsParenBeforeExpressionBrace(tokenContext) &&\n isObjectPattern(node.left)\n ) {\n return true;\n } else {\n return ConditionalExpression(node, parent);\n }\n}\n\nexport function LogicalExpression(\n node: t.LogicalExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n if (isTSTypeExpression(parentType)) return true;\n if (parentType !== \"LogicalExpression\") return false;\n switch (node.operator) {\n case \"||\":\n return parent.operator === \"??\" || parent.operator === \"&&\";\n case \"&&\":\n return parent.operator === \"??\";\n case \"??\":\n return parent.operator !== \"??\";\n }\n}\n\nexport function Identifier(\n node: t.Identifier,\n parent: t.Node,\n tokenContext: number,\n _inForInit: boolean,\n getRawIdentifier: (node: t.Identifier) => string,\n): boolean {\n const parentType = parent.type;\n // 13.15.2 AssignmentExpression RS: Evaluation\n // (fn) = function () {};\n if (\n node.extra?.parenthesized &&\n parentType === \"AssignmentExpression\" &&\n parent.left === node\n ) {\n const rightType = parent.right.type;\n if (\n (rightType === \"FunctionExpression\" || rightType === \"ClassExpression\") &&\n parent.right.id == null\n ) {\n return true;\n }\n }\n\n if (getRawIdentifier && getRawIdentifier(node) !== node.name) {\n return false;\n }\n\n // Non-strict code allows the identifier `let`, but it cannot occur as-is in\n // certain contexts to avoid ambiguity with contextual keyword `let`.\n if (node.name === \"let\") {\n // Some contexts only forbid `let [`, so check if the next token would\n // be the left bracket of a computed member expression.\n const isFollowedByBracket =\n isMemberExpression(parent, {\n object: node,\n computed: true,\n }) ||\n isOptionalMemberExpression(parent, {\n object: node,\n computed: true,\n optional: false,\n });\n if (\n isFollowedByBracket &&\n tokenContext &\n (TokenContext.expressionStatement |\n TokenContext.forHead |\n TokenContext.forInHead)\n ) {\n return true;\n }\n return Boolean(tokenContext & TokenContext.forOfHead);\n }\n\n // ECMAScript specifically forbids a for-of loop from starting with the\n // token sequence `for (async of`, because it would be ambiguous with\n // `for (async of => {};;)`, so we need to add extra parentheses.\n return (\n node.name === \"async\" &&\n isForOfStatement(parent, { left: node, await: false })\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,EAAA,GAAAC,OAAA;AAcA,IAAAC,MAAA,GAAAD,OAAA;AAA0C;EAbxCE,qBAAqB;EACrBC,kBAAkB;EAClBC,gBAAgB;EAChBC,gBAAgB;EAChBC,mBAAmB;EACnBC,kBAAkB;EAClBC,eAAe;EACfC,0BAA0B;EAC1BC,iBAAiB;EACjBC;AAAW,IAAAZ,EAAA;AAMb,MAAMa,UAAU,GAAG,IAAIC,GAAG,CAAC,CACzB,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,GAAG,EAAE,CAAC,CAAC,EACR,CAAC,GAAG,EAAE,CAAC,CAAC,EACR,CAAC,GAAG,EAAE,CAAC,CAAC,EACR,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,KAAK,EAAE,CAAC,CAAC,EACV,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,KAAK,EAAE,CAAC,CAAC,EACV,CAAC,GAAG,EAAE,CAAC,CAAC,EACR,CAAC,GAAG,EAAE,CAAC,CAAC,EACR,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,YAAY,EAAE,CAAC,CAAC,EACjB,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,CAAC,IAAI,EAAE,CAAC,CAAC,EACT,C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,CAAC+D,IAAI,EAAE;IAC5D,OAAO,KAAK;EACd;EAIA,IAAI/D,IAAI,CAAC+D,IAAI,KAAK,KAAK,EAAE;IAGvB,MAAMC,mBAAmB,GACvBxE,kBAAkB,CAACc,MAAM,EAAE;MACzBK,MAAM,EAAEX,IAAI;MACZiE,QAAQ,EAAE;IACZ,CAAC,CAAC,IACFvE,0BAA0B,CAACY,MAAM,EAAE;MACjCK,MAAM,EAAEX,IAAI;MACZiE,QAAQ,EAAE,IAAI;MACdC,QAAQ,EAAE;IACZ,CAAC,CAAC;IACJ,IACEF,mBAAmB,IACnBhD,YAAY,IACTE,mBAAY,CAACI,mBAAmB,GAC/BJ,mBAAY,CAACiD,OAAO,GACpBjD,mBAAY,CAACkD,SAAS,CAAC,EAC3B;MACA,OAAO,IAAI;IACb;IACA,OAAOnD,OAAO,CAACD,YAAY,GAAGE,mBAAY,CAACmD,SAAS,CAAC;EACvD;EAKA,OACErE,IAAI,CAAC+D,IAAI,KAAK,OAAO,IACrBzE,gBAAgB,CAACgB,MAAM,EAAE;IAAEsB,IAAI,EAAE5B,IAAI;IAAEsE,KAAK,EAAE;EAAM,CAAC,CAAC;AAE1D","ignoreList":[]}1 {"version":3,"names":["_t","require","_index","isArrayTypeAnnotation","isBinaryExpression","isCallExpression","isForOfStatement","isIndexedAccessType","isMemberExpression","isObjectPattern","isOptionalMemberExpression","isYieldExpression","isStatement","PRECEDENCE","Map","getBinaryPrecedence","node","nodeType","get","operator","isTSTypeExpression","isClassExtendsClause","parent","parentType","type","superClass","hasPostfixPart","object","callee","tag","NullableTypeAnnotation","FunctionTypeAnnotation","tokenContext","Boolean","TokenContext","arrowFlowReturnType","UpdateExpression","needsParenBeforeExpressionBrace","expressionStatement","arrowBody","ObjectExpression","DoExpression","async","Binary","left","parentPos","nodePos","right","undefined","UnionTypeAnnotation","OptionalIndexedAccessType","objectType","TSAsExpression","TSUnionType","TSInferType","TSInstantiationExpression","typeParameters","BinaryExpression","inForStatementInit","SequenceExpression","property","YieldExpression","test","ClassExpression","exportDefault","UnaryLike","FunctionExpression","ConditionalExpression","OptionalMemberExpression","AssignmentExpression","LogicalExpression","Identifier","_inForInit","getRawIdentifier","_node$extra","extra","parenthesized","rightType","id","name","isFollowedByBracket","computed","optional","forHead","forInHead","forOfHead","await"],"sources":["../../src/node/parentheses.ts"],"sourcesContent":["import {\n isArrayTypeAnnotation,\n isBinaryExpression,\n isCallExpression,\n isForOfStatement,\n isIndexedAccessType,\n isMemberExpression,\n isObjectPattern,\n isOptionalMemberExpression,\n isYieldExpression,\n isStatement,\n} from \"@babel/types\";\nimport type * as t from \"@babel/types\";\n\nimport { TokenContext } from \"./index.ts\";\n\nconst PRECEDENCE = new Map([\n [\"||\", 0],\n [\"??\", 0],\n [\"|>\", 0],\n [\"&&\", 1],\n [\"|\", 2],\n [\"^\", 3],\n [\"&\", 4],\n [\"==\", 5],\n [\"===\", 5],\n [\"!=\", 5],\n [\"!==\", 5],\n [\"<\", 6],\n [\">\", 6],\n [\"<=\", 6],\n [\">=\", 6],\n [\"in\", 6],\n [\"instanceof\", 6],\n [\">>\", 7],\n [\"<<\", 7],\n [\">>>\", 7],\n [\"+\", 8],\n [\"-\", 8],\n [\"*\", 9],\n [\"/\", 9],\n [\"%\", 9],\n [\"**\", 10],\n]);\n\nfunction getBinaryPrecedence(\n node: t.Binary | t.TSAsExpression | t.TSSatisfiesExpression,\n nodeType: string,\n): number;\nfunction getBinaryPrecedence(\n node: t.Node,\n nodeType: string,\n): number | undefined;\nfunction getBinaryPrecedence(node: t.Node, nodeType: string) {\n if (nodeType === \"BinaryExpression\" || nodeType === \"LogicalExpression\") {\n return PRECEDENCE.get((node as t.Binary).operator);\n }\n if (nodeType === \"TSAsExpression\" || nodeType === \"TSSatisfiesExpression\") {\n return PRECEDENCE.get(\"in\");\n }\n}\n\nfunction isTSTypeExpression(nodeType: string) {\n return (\n nodeType === \"TSAsExpression\" ||\n nodeType === \"TSSatisfiesExpression\" ||\n nodeType === \"TSTypeAssertion\"\n );\n}\n\nconst isClassExtendsClause = (\n node: t.Node,\n parent: t.Node,\n): parent is t.Class => {\n const parentType = parent.type;\n return (\n (parentType === \"ClassDeclaration\" || parentType === \"ClassExpression\") &&\n parent.superClass === node\n );\n};\n\nconst hasPostfixPart = (node: t.Node, parent: t.Node) => {\n const parentType = parent.type;\n return (\n ((parentType === \"MemberExpression\" ||\n parentType === \"OptionalMemberExpression\") &&\n parent.object === node) ||\n ((parentType === \"CallExpression\" ||\n parentType === \"OptionalCallExpression\" ||\n parentType === \"NewExpression\") &&\n parent.callee === node) ||\n (parentType === \"TaggedTemplateExpression\" && parent.tag === node) ||\n parentType === \"TSNonNullExpression\"\n );\n};\n\nexport function NullableTypeAnnotation(\n node: t.NullableTypeAnnotation,\n parent: t.Node,\n): boolean {\n return isArrayTypeAnnotation(parent);\n}\n\nexport function FunctionTypeAnnotation(\n node: t.FunctionTypeAnnotation,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n const parentType = parent.type;\n return (\n // (() => A) | (() => B)\n parentType === \"UnionTypeAnnotation\" ||\n // (() => A) & (() => B)\n parentType === \"IntersectionTypeAnnotation\" ||\n // (() => A)[]\n parentType === \"ArrayTypeAnnotation\" ||\n Boolean(tokenContext & TokenContext.arrowFlowReturnType)\n );\n}\n\nexport function UpdateExpression(\n node: t.UpdateExpression,\n parent: t.Node,\n): boolean {\n return hasPostfixPart(node, parent) || isClassExtendsClause(node, parent);\n}\n\nfunction needsParenBeforeExpressionBrace(tokenContext: number) {\n return Boolean(\n tokenContext & (TokenContext.expressionStatement | TokenContext.arrowBody),\n );\n}\n\nexport function ObjectExpression(\n node: t.ObjectExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return needsParenBeforeExpressionBrace(tokenContext);\n}\n\nexport function DoExpression(\n node: t.DoExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n // `async do` can start an expression statement\n return (\n !node.async && Boolean(tokenContext & TokenContext.expressionStatement)\n );\n}\n\nexport function Binary(\n node: t.Binary | t.TSAsExpression | t.TSSatisfiesExpression,\n parent: t.Node,\n): boolean | undefined {\n const parentType = parent.type;\n if (\n node.type === \"BinaryExpression\" &&\n node.operator === \"**\" &&\n parentType === \"BinaryExpression\" &&\n parent.operator === \"**\"\n ) {\n return parent.left === node;\n }\n\n if (isClassExtendsClause(node, parent)) {\n return true;\n }\n\n if (\n hasPostfixPart(node, parent) ||\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n parentType === \"AwaitExpression\"\n ) {\n return true;\n }\n\n const parentPos = getBinaryPrecedence(parent, parentType);\n if (parentPos != null) {\n const nodePos = getBinaryPrecedence(node, node.type);\n if (\n // Logical expressions with the same precedence don't need parens.\n (parentPos === nodePos &&\n parentType === \"BinaryExpression\" &&\n parent.right === node) ||\n parentPos > nodePos\n ) {\n return true;\n }\n }\n\n return undefined;\n}\n\nexport function UnionTypeAnnotation(\n node: t.UnionTypeAnnotation,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n return (\n parentType === \"ArrayTypeAnnotation\" ||\n parentType === \"NullableTypeAnnotation\" ||\n parentType === \"IntersectionTypeAnnotation\" ||\n parentType === \"UnionTypeAnnotation\"\n );\n}\n\nexport { UnionTypeAnnotation as IntersectionTypeAnnotation };\n\nexport function OptionalIndexedAccessType(\n node: t.OptionalIndexedAccessType,\n parent: t.Node,\n): boolean {\n return isIndexedAccessType(parent) && parent.objectType === node;\n}\n\nexport function TSAsExpression(\n node: t.TSAsExpression | t.TSSatisfiesExpression,\n parent: t.Node,\n): boolean {\n if (\n (parent.type === \"AssignmentExpression\" ||\n parent.type === \"AssignmentPattern\") &&\n parent.left === node\n ) {\n return true;\n }\n if (\n parent.type === \"BinaryExpression\" &&\n (parent.operator === \"|\" || parent.operator === \"&\") &&\n node === parent.left\n ) {\n return true;\n }\n return Binary(node, parent);\n}\n\nexport { TSAsExpression as TSSatisfiesExpression };\n\nexport { UnaryLike as TSTypeAssertion };\n\nexport function TSUnionType(node: t.TSUnionType, parent: t.Node): boolean {\n const parentType = parent.type;\n return (\n parentType === \"TSArrayType\" ||\n parentType === \"TSOptionalType\" ||\n parentType === \"TSIntersectionType\" ||\n parentType === \"TSRestType\"\n );\n}\n\nexport { TSUnionType as TSIntersectionType };\n\nexport function TSInferType(node: t.TSInferType, parent: t.Node): boolean {\n const parentType = parent.type;\n return parentType === \"TSArrayType\" || parentType === \"TSOptionalType\";\n}\n\nexport function TSInstantiationExpression(\n node: t.TSInstantiationExpression,\n parent: t.Node,\n) {\n const parentType = parent.type;\n return (\n (parentType === \"CallExpression\" ||\n parentType === \"OptionalCallExpression\" ||\n parentType === \"NewExpression\" ||\n parentType === \"TSInstantiationExpression\") &&\n !!(process.env.BABEL_8_BREAKING\n ? // @ts-ignore(Babel 7 vs Babel 8) Babel 8 AST\n parent.typeArguments\n : // @ts-ignore(Babel 7 vs Babel 8) Babel 7 AST\n parent.typeParameters)\n );\n}\n\nexport function BinaryExpression(\n node: t.BinaryExpression,\n parent: t.Node,\n tokenContext: unknown,\n inForStatementInit: boolean,\n): boolean {\n // for ((1 in []);;);\n // for (var x = (1 in []) in 2);\n return node.operator === \"in\" && inForStatementInit;\n}\n\nexport function SequenceExpression(\n node: t.SequenceExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n if (\n parentType === \"SequenceExpression\" ||\n parentType === \"ParenthesizedExpression\" ||\n (parentType === \"MemberExpression\" && parent.property === node) ||\n (parentType === \"OptionalMemberExpression\" && parent.property === node) ||\n parentType === \"TemplateLiteral\"\n ) {\n return false;\n }\n if (parentType === \"ClassDeclaration\") {\n return true;\n }\n if (parentType === \"ForOfStatement\") {\n return parent.right === node;\n }\n if (parentType === \"ExportDefaultDeclaration\") {\n return true;\n }\n\n return !isStatement(parent);\n}\n\nexport function YieldExpression(\n node: t.YieldExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n return (\n parentType === \"BinaryExpression\" ||\n parentType === \"LogicalExpression\" ||\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n hasPostfixPart(node, parent) ||\n (parentType === \"AwaitExpression\" && isYieldExpression(node)) ||\n (parentType === \"ConditionalExpression\" && node === parent.test) ||\n isClassExtendsClause(node, parent) ||\n isTSTypeExpression(parentType)\n );\n}\n\nexport { YieldExpression as AwaitExpression };\n\nexport function ClassExpression(\n node: t.ClassExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return Boolean(\n tokenContext &\n (TokenContext.expressionStatement | TokenContext.exportDefault),\n );\n}\n\nexport function UnaryLike(\n node:\n | t.UnaryLike\n | t.TSTypeAssertion\n | t.ArrowFunctionExpression\n | t.ConditionalExpression\n | t.AssignmentExpression,\n parent: t.Node,\n): boolean {\n return (\n hasPostfixPart(node, parent) ||\n (isBinaryExpression(parent) &&\n parent.operator === \"**\" &&\n parent.left === node) ||\n isClassExtendsClause(node, parent)\n );\n}\n\nexport function FunctionExpression(\n node: t.FunctionExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n return Boolean(\n tokenContext &\n (TokenContext.expressionStatement | TokenContext.exportDefault),\n );\n}\n\nexport function ConditionalExpression(\n node:\n | t.ConditionalExpression\n | t.ArrowFunctionExpression\n | t.AssignmentExpression,\n parent?: t.Node,\n): boolean {\n const parentType = parent.type;\n if (\n parentType === \"UnaryExpression\" ||\n parentType === \"SpreadElement\" ||\n parentType === \"BinaryExpression\" ||\n parentType === \"LogicalExpression\" ||\n (parentType === \"ConditionalExpression\" && parent.test === node) ||\n parentType === \"AwaitExpression\" ||\n isTSTypeExpression(parentType)\n ) {\n return true;\n }\n\n return UnaryLike(node, parent);\n}\n\nexport { ConditionalExpression as ArrowFunctionExpression };\n\nexport function OptionalMemberExpression(\n node: t.OptionalMemberExpression,\n parent: t.Node,\n): boolean {\n return (\n (isCallExpression(parent) && parent.callee === node) ||\n (isMemberExpression(parent) && parent.object === node)\n );\n}\n\nexport { OptionalMemberExpression as OptionalCallExpression };\n\nexport function AssignmentExpression(\n node: t.AssignmentExpression,\n parent: t.Node,\n tokenContext: number,\n): boolean {\n if (\n needsParenBeforeExpressionBrace(tokenContext) &&\n isObjectPattern(node.left)\n ) {\n return true;\n } else {\n return ConditionalExpression(node, parent);\n }\n}\n\nexport function LogicalExpression(\n node: t.LogicalExpression,\n parent: t.Node,\n): boolean {\n const parentType = parent.type;\n if (isTSTypeExpression(parentType)) return true;\n if (parentType !== \"LogicalExpression\") return false;\n switch (node.operator) {\n case \"||\":\n return parent.operator === \"??\" || parent.operator === \"&&\";\n case \"&&\":\n return parent.operator === \"??\";\n case \"??\":\n return parent.operator !== \"??\";\n }\n}\n\nexport function Identifier(\n node: t.Identifier,\n parent: t.Node,\n tokenContext: number,\n _inForInit: boolean,\n getRawIdentifier: (node: t.Identifier) => string,\n): boolean {\n const parentType = parent.type;\n // 13.15.2 AssignmentExpression RS: Evaluation\n // (fn) = function () {};\n if (\n node.extra?.parenthesized &&\n parentType === \"AssignmentExpression\" &&\n parent.left === node\n ) {\n const rightType = parent.right.type;\n if (\n (rightType === \"FunctionExpression\" || rightType === \"ClassExpression\") &&\n parent.right.id == null\n ) {\n return true;\n }\n }\n\n if (getRawIdentifier && getRawIdentifier(node) !== node.name) {\n return false;\n }\n\n // Non-strict code allows the identifier `let`, but it cannot occur as-is in\n // certain contexts to avoid ambiguity with contextual keyword `let`.\n if (node.name === \"let\") {\n // Some contexts only forbid `let [`, so check if the next token would\n // be the left bracket of a computed member expression.\n const isFollowedByBracket =\n isMemberExpression(parent, {\n object: node,\n computed: true,\n }) ||\n isOptionalMemberExpression(parent, {\n object: node,\n computed: true,\n optional: false,\n });\n if (\n isFollowedByBracket &&\n tokenContext &\n (TokenContext.expressionStatement |\n TokenContext.forHead |\n TokenContext.forInHead)\n ) {\n return true;\n }\n return Boolean(tokenContext & TokenContext.forOfHead);\n }\n\n // ECMAScript specifically forbids a for-of loop from starting with the\n // token sequence `for (async of`, because it would be ambiguous with\n // `for (async of => {};;)`, so we need to add extra parentheses.\n return (\n node.name === \"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AAQ,EAAE;IACZ,CAAC,CAAC,IACFvE,0BAA0B,CAACY,MAAM,EAAE;MACjCK,MAAM,EAAEX,IAAI;MACZiE,QAAQ,EAAE,IAAI;MACdC,QAAQ,EAAE;IACZ,CAAC,CAAC;IACJ,IACEF,mBAAmB,IACnBhD,YAAY,IACTE,mBAAY,CAACI,mBAAmB,GAC/BJ,mBAAY,CAACiD,OAAO,GACpBjD,mBAAY,CAACkD,SAAS,CAAC,EAC3B;MACA,OAAO,IAAI;IACb;IACA,OAAOnD,OAAO,CAACD,YAAY,GAAGE,mBAAY,CAACmD,SAAS,CAAC;EACvD;EAKA,OACErE,IAAI,CAAC+D,IAAI,KAAK,OAAO,IACrBzE,gBAAgB,CAACgB,MAAM,EAAE;IAAEsB,IAAI,EAAE5B,IAAI;IAAEsE,KAAK,EAAE;EAAM,CAAC,CAAC;AAE1D","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/lib/printer.js
r0c6b92a r79a0317 10 10 var _tokenMap = require("./token-map.js"); 11 11 var generatorFunctions = require("./generators/index.js"); 12 var _deprecated = require("./generators/deprecated.js"); 12 13 const { 13 14 isExpression, … … 16 17 isClassBody, 17 18 isTSInterfaceBody, 18 isTSEnum Declaration19 isTSEnumMember 19 20 } = _t; 20 21 const SCIENTIFIC_NOTATION = /e/i; … … 50 51 this.tokenMap = null; 51 52 this._boundGetRawIdentifier = this._getRawIdentifier.bind(this); 53 this._printSemicolonBeforeNextNode = -1; 54 this._printSemicolonBeforeNextToken = -1; 52 55 this.format = format; 53 56 this._tokens = tokens; … … 114 117 if (node.start != null && node.end != null) { 115 118 if (!this.tokenMap.endMatches(node, ";")) { 119 this._printSemicolonBeforeNextNode = this._buf.getCurrentLine(); 116 120 return; 117 121 } … … 151 155 this.tokenContext = 0; 152 156 this._maybePrintInnerComments(str); 157 this._maybeAddAuxComment(); 158 if (this.tokenMap) this._catchUpToCurrentToken(str); 153 159 if (this._endsWithWord || this._endsWithDiv && str.charCodeAt(0) === 47) { 154 160 this._space(); 155 161 } 156 this._maybeAddAuxComment();157 162 this._append(str, false); 158 163 this._endsWithWord = true; … … 173 178 this.tokenContext = 0; 174 179 this._maybePrintInnerComments(str, occurrenceCount); 180 this._maybeAddAuxComment(); 181 if (this.tokenMap) this._catchUpToCurrentToken(str, occurrenceCount); 175 182 const lastChar = this.getLastChar(); 176 183 const strFirst = str.charCodeAt(0); … … 178 185 this._space(); 179 186 } 180 this._maybeAddAuxComment(); 181 this._append(str, maybeNewline, occurrenceCount); 187 this._append(str, maybeNewline); 182 188 this._noLineTerminator = false; 183 189 } 184 190 tokenChar(char) { 185 191 this.tokenContext = 0; 186 this._maybePrintInnerComments(String.fromCharCode(char)); 192 const str = String.fromCharCode(char); 193 this._maybePrintInnerComments(str); 194 this._maybeAddAuxComment(); 195 if (this.tokenMap) this._catchUpToCurrentToken(str); 187 196 const lastChar = this.getLastChar(); 188 197 if (char === 43 && lastChar === 43 || char === 45 && lastChar === 45 || char === 46 && this._endsWithInteger) { 189 198 this._space(); 190 199 } 191 this._maybeAddAuxComment();192 200 this._appendChar(char); 193 201 this._noLineTerminator = false; … … 251 259 this._queue(10); 252 260 } 253 _append(str, maybeNewline, occurrenceCount = 0) { 254 if (this.tokenMap) { 255 const token = this.tokenMap.findMatching(this._currentNode, str, occurrenceCount); 256 if (token) this._catchUpTo(token.loc.start); 257 } 261 _catchUpToCurrentToken(str, occurrenceCount = 0) { 262 const token = this.tokenMap.findMatching(this._currentNode, str, occurrenceCount); 263 if (token) this._catchUpTo(token.loc.start); 264 if (this._printSemicolonBeforeNextToken !== -1 && this._printSemicolonBeforeNextToken === this._buf.getCurrentLine()) { 265 this._buf.appendChar(59); 266 this._endsWithWord = false; 267 this._endsWithInteger = false; 268 this._endsWithDiv = false; 269 } 270 this._printSemicolonBeforeNextToken = -1; 271 this._printSemicolonBeforeNextNode = -1; 272 } 273 _append(str, maybeNewline) { 258 274 this._maybeIndent(str.charCodeAt(0)); 259 275 this._buf.append(str, maybeNewline); … … 263 279 } 264 280 _appendChar(char) { 265 if (this.tokenMap) {266 const token = this.tokenMap.findMatching(this._currentNode, String.fromCharCode(char));267 if (token) this._catchUpTo(token.loc.start);268 }269 281 this._maybeIndent(char); 270 282 this._buf.appendChar(char); … … 350 362 const parent = this._currentNode; 351 363 this._currentNode = node; 364 if (this.tokenMap) { 365 this._printSemicolonBeforeNextToken = this._printSemicolonBeforeNextNode; 366 } 352 367 const oldInAux = this._insideAux; 353 368 this._insideAux = node.loc == null; … … 460 475 } 461 476 } 462 printJoin(nodes, opts = {}) {477 printJoin(nodes, statement, indent, separator, printTrailingSeparator, addNewlines, iterator, trailingCommentsLineOffset) { 463 478 if (!(nodes != null && nodes.length)) return; 464 let {465 indent466 } = opts;467 479 if (indent == null && this.format.retainLines) { 468 480 var _nodes$0$loc; … … 474 486 if (indent) this.indent(); 475 487 const newlineOpts = { 476 addNewlines: opts.addNewlines,488 addNewlines: addNewlines, 477 489 nextNodeStartLine: 0 478 490 }; 479 const separator = opts.separator ? opts.separator.bind(this) : null;491 const boundSeparator = separator == null ? void 0 : separator.bind(this); 480 492 const len = nodes.length; 481 493 for (let i = 0; i < len; i++) { 482 494 const node = nodes[i]; 483 495 if (!node) continue; 484 if ( opts.statement) this._printNewline(i === 0, newlineOpts);485 this.print(node, undefined, opts.trailingCommentsLineOffset || 0);486 opts.iterator == null || opts.iterator(node, i);487 if ( separator != null) {488 if (i < len - 1) separator(i, false);else if (opts.printTrailingSeparator) separator(i, true);489 } 490 if ( opts.statement) {496 if (statement) this._printNewline(i === 0, newlineOpts); 497 this.print(node, undefined, trailingCommentsLineOffset || 0); 498 iterator == null || iterator(node, i); 499 if (boundSeparator != null) { 500 if (i < len - 1) boundSeparator(i, false);else if (printTrailingSeparator) boundSeparator(i, true); 501 } 502 if (statement) { 491 503 var _node$trailingComment2; 492 504 if (!((_node$trailingComment2 = node.trailingComments) != null && _node$trailingComment2.length)) { … … 560 572 this._indentInnerComments = false; 561 573 } 562 printSequence(nodes, opts = {}) { 563 var _opts$indent; 564 opts.statement = true; 565 (_opts$indent = opts.indent) != null ? _opts$indent : opts.indent = false; 566 this.printJoin(nodes, opts); 567 } 568 printList(items, opts = {}) { 569 if (opts.separator == null) { 570 opts.separator = commaSeparator; 571 } 572 this.printJoin(items, opts); 574 printSequence(nodes, indent, trailingCommentsLineOffset, addNewlines) { 575 this.printJoin(nodes, true, indent != null ? indent : false, undefined, undefined, addNewlines, undefined, trailingCommentsLineOffset); 576 } 577 printList(items, printTrailingSeparator, statement, indent, separator, iterator) { 578 this.printJoin(items, statement, indent, separator != null ? separator : commaSeparator, printTrailingSeparator, undefined, iterator); 573 579 } 574 580 shouldPrintTrailingComma(listEnd) { … … 656 662 } 657 663 if (this._endsWithDiv) this._space(); 658 this.source("start", comment.loc); 659 this._append(val, isBlockComment); 664 if (this.tokenMap) { 665 const { 666 _printSemicolonBeforeNextToken, 667 _printSemicolonBeforeNextNode 668 } = this; 669 this._printSemicolonBeforeNextToken = -1; 670 this._printSemicolonBeforeNextNode = -1; 671 this.source("start", comment.loc); 672 this._append(val, isBlockComment); 673 this._printSemicolonBeforeNextNode = _printSemicolonBeforeNextNode; 674 this._printSemicolonBeforeNextToken = _printSemicolonBeforeNextToken; 675 } else { 676 this.source("start", comment.loc); 677 this._append(val, isBlockComment); 678 } 660 679 if (!isBlockComment && !noLineTerminator) { 661 680 this.newline(1, true); … … 722 741 if (len === 1) { 723 742 const singleLine = comment.loc ? comment.loc.start.line === comment.loc.end.line : !HAS_NEWLINE.test(comment.value); 724 const shouldSkipNewline = singleLine && !isStatement(node) && !isClassBody(parent) && !isTSInterfaceBody(parent) && !isTSEnum Declaration(parent);743 const shouldSkipNewline = singleLine && !isStatement(node) && !isClassBody(parent) && !isTSInterfaceBody(parent) && !isTSEnumMember(node); 725 744 if (type === 0) { 726 745 this._printComment(comment, shouldSkipNewline && node.type !== "ObjectExpression" || singleLine && isFunction(parent, { … … 746 765 Object.assign(Printer.prototype, generatorFunctions); 747 766 { 748 Printer.prototype.Noop = function Noop() {};767 (0, _deprecated.addDeprecatedGenerators)(Printer); 749 768 } 750 769 var _default = exports.default = Printer; -
imaps-frontend/node_modules/@babel/generator/lib/printer.js.map
r0c6b92a r79a0317 1 {"version":3,"names":["_buffer","require","n","_t","_tokenMap","generatorFunctions"," isExpression","isFunction","isStatement","isClassBody","isTSInterfaceBody","isTSEnumDeclaration","SCIENTIFIC_NOTATION","ZERO_DECIMAL_INTEGER","HAS_NEWLINE","HAS_NEWLINE_OR_BlOCK_COMMENT_END","commentIsNewline","c","type","test","value","needsParens","Printer","constructor","format","map","tokens","originalCode","inForStatementInit","tokenContext","_tokens","_originalCode","_currentNode","_indent","_indentRepeat","_insideAux","_noLineTerminator","_noLineTerminatorAfterNode","_printAuxAfterOnNextUserNode","_printedComments","Set","_endsWithInteger","_endsWithWord","_endsWithDiv","_lastCommentLine","_endsWithInnerRaw","_indentInnerComments","tokenMap","_boundGetRawIdentifier","_getRawIdentifier","bind","indent","style","length","_inputMap","_buf","Buffer","enterForStatementInit","enterDelimited","oldInForStatementInit","oldNoLineTerminatorAfterNode","generate","ast","preserveFormat","TokenMap","print","_maybeAddAuxComment","get","compact","concise","dedent","semicolon","force","_appendChar","node","start","end","endMatches","indexes","getIndexes","_catchUpTo","loc","_queue","rightBrace","minified","removeLastSemicolon","sourceWithOffset","token","rightParens","space","_space","hasContent","lastCp","getLastChar","word","str","noLineTerminatorAfter","_maybePrintInnerComments","charCodeAt","_append","number","isNonDecimalLiteral","secondChar","Number","isInteger","maybeNewline","occurrenceCount","lastChar","strFirst","tokenChar","char","String","fromCharCode","newline","i","retainLines","getNewlineCount","j","_newline","endsWith","endsWithCharAndNewline","removeTrailingNewline","exactSource","cb","_catchUp","source","prop","columnOffset","sourceIdentifierName","identifierName","pos","_canMarkIdName","sourcePosition","_sourcePosition","identifierNamePos","findMatching","_maybeIndent","append","appendChar","queue","firstChar","queueIndentation","_getIndent","_shouldIndent","catchUp","line","count","getCurrentLine","column","index","spacesCount","getCurrentColumn","spaces","slice","replace","repeat","printTerminatorless","trailingCommentsLineOffset","_node$extra","_node$leadingComments","_node$leadingComments2","nodeType","oldConcise","_compact","printMethod","undefined","ReferenceError","JSON","stringify","name","parent","oldInAux","parenthesized","extra","shouldPrintParens","retainFunctionParens","leadingComments","parentType","callee","indentParenthesized","some","oldInForStatementInitWasTrue","isLastChild","_node$trailingComment","trailingComments","_printLeadingComments","_printTrailingComments","enteredPositionlessNode","_printAuxBeforeComment","_printAuxAfterComment","comment","auxiliaryCommentBefore","_printComment","auxiliaryCommentAfter","getPossibleRaw","raw","rawValue","printJoin","nodes","opts","_nodes$0$loc","startLine","newlineOpts","addNewlines","nextNodeStartLine","separator","len","statement","_printNewline","iterator","printTrailingSeparator","_node$trailingComment2","_nextNode$loc","nextNode","printAndIndentOnComments","printBlock","body","lineOffset","innerComments","_printComments","comments","nextTokenStr","nextTokenOccurrenceCount","_this$tokenMap","printInnerComments","nextToken","hasSpace","printedCommentsCount","size","noIndentInnerCommentsHere","printSequence","_opts$indent","printList","items","commaSeparator","shouldPrintTrailingComma","listEnd","listEndIndex","findLastIndex","matchesOriginal","newLine","lastCommentLine","offset","_shouldPrintComment","ignore","has","commentTok","find","add","shouldPrintComment","skipNewLines","noLineTerminator","isBlockComment","printNewLines","lastCharCode","val","adjustMultilineComment","_comment$loc","newlineRegex","RegExp","indentSize","nodeLoc","hasLoc","nodeStartLine","nodeEndLine","lastLine","leadingCommentNewline","shouldPrint","commentStartLine","commentEndLine","Math","max","min","singleLine","shouldSkipNewline","properties","Object","assign","prototype","Noop","_default","exports","default","last"],"sources":["../src/printer.ts"],"sourcesContent":["import Buffer, { type Pos } from \"./buffer.ts\";\nimport type { Loc } from \"./buffer.ts\";\nimport * as n from \"./node/index.ts\";\nimport type * as t from \"@babel/types\";\nimport {\n isExpression,\n isFunction,\n isStatement,\n isClassBody,\n isTSInterfaceBody,\n isTSEnumDeclaration,\n} from \"@babel/types\";\nimport type { Opts as jsescOptions } from \"jsesc\";\n\nimport { TokenMap } from \"./token-map.ts\";\nimport type { GeneratorOptions } from \"./index.ts\";\nimport * as generatorFunctions from \"./generators/index.ts\";\nimport type SourceMap from \"./source-map.ts\";\nimport type { TraceMap } from \"@jridgewell/trace-mapping\";\nimport type { Token } from \"@babel/parser\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\n\nconst SCIENTIFIC_NOTATION = /e/i;\nconst ZERO_DECIMAL_INTEGER = /\\.0+$/;\nconst HAS_NEWLINE = /[\\n\\r\\u2028\\u2029]/;\nconst HAS_NEWLINE_OR_BlOCK_COMMENT_END = /[\\n\\r\\u2028\\u2029]|\\*\\//;\n\nfunction commentIsNewline(c: t.Comment) {\n return c.type === \"CommentLine\" || HAS_NEWLINE.test(c.value);\n}\n\nconst { needsParens } = n;\n\nconst enum COMMENT_TYPE {\n LEADING,\n INNER,\n TRAILING,\n}\n\nconst enum COMMENT_SKIP_NEWLINE {\n DEFAULT,\n ALL,\n LEADING,\n TRAILING,\n}\n\nconst enum PRINT_COMMENT_HINT {\n SKIP,\n ALLOW,\n DEFER,\n}\n\nexport type Format = {\n shouldPrintComment: (comment: string) => boolean;\n preserveFormat: boolean;\n retainLines: boolean;\n retainFunctionParens: boolean;\n comments: boolean;\n auxiliaryCommentBefore: string;\n auxiliaryCommentAfter: string;\n compact: boolean | \"auto\";\n minified: boolean;\n concise: boolean;\n indent: {\n adjustMultilineComment: boolean;\n style: string;\n };\n /**\n * @deprecated Removed in Babel 8, syntax type is always 'hash'\n */\n recordAndTupleSyntaxType?: GeneratorOptions[\"recordAndTupleSyntaxType\"];\n jsescOption: jsescOptions;\n /**\n * @deprecated Removed in Babel 8, use `jsescOption` instead\n */\n jsonCompatibleStrings?: boolean;\n /**\n * For use with the Hack-style pipe operator.\n * Changes what token is used for pipe bodies’ topic references.\n */\n topicToken?: GeneratorOptions[\"topicToken\"];\n /**\n * @deprecated Removed in Babel 8\n */\n decoratorsBeforeExport?: boolean;\n /**\n * The import attributes syntax style:\n * - \"with\" : `import { a } from \"b\" with { type: \"json\" };`\n * - \"assert\" : `import { a } from \"b\" assert { type: \"json\" };`\n * - \"with-legacy\" : `import { a } from \"b\" with type: \"json\";`\n */\n importAttributesKeyword?: \"with\" | \"assert\" | \"with-legacy\";\n};\n\ninterface AddNewlinesOptions {\n addNewlines(leading: boolean, node: t.Node): number;\n nextNodeStartLine: number;\n}\n\ninterface PrintSequenceOptions extends Partial<AddNewlinesOptions> {\n statement?: boolean;\n indent?: boolean;\n trailingCommentsLineOffset?: number;\n}\n\ninterface PrintListOptions {\n separator?: (this: Printer, occurrenceCount: number, last: boolean) => void;\n iterator?: (node: t.Node, index: number) => void;\n statement?: boolean;\n indent?: boolean;\n printTrailingSeparator?: boolean;\n}\n\nexport type PrintJoinOptions = PrintListOptions & PrintSequenceOptions;\nclass Printer {\n constructor(\n format: Format,\n map: SourceMap,\n tokens?: Token[],\n originalCode?: string,\n ) {\n this.format = format;\n\n this._tokens = tokens;\n this._originalCode = originalCode;\n\n this._indentRepeat = format.indent.style.length;\n\n this._inputMap = map?._inputMap;\n\n this._buf = new Buffer(map, format.indent.style[0]);\n }\n declare _inputMap: TraceMap;\n\n declare format: Format;\n\n inForStatementInit: boolean = false;\n enterForStatementInit() {\n if (this.inForStatementInit) return () => {};\n this.inForStatementInit = true;\n return () => {\n this.inForStatementInit = false;\n };\n }\n\n enterDelimited() {\n const oldInForStatementInit = this.inForStatementInit;\n const oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n if (\n oldInForStatementInit === false &&\n oldNoLineTerminatorAfterNode === null\n ) {\n return () => {};\n }\n this.inForStatementInit = false;\n this._noLineTerminatorAfterNode = null;\n return () => {\n this.inForStatementInit = oldInForStatementInit;\n this._noLineTerminatorAfterNode = oldNoLineTerminatorAfterNode;\n };\n }\n\n tokenContext: number = 0;\n\n _tokens: Token[] = null;\n _originalCode: string | null = null;\n\n declare _buf: Buffer;\n _currentNode: t.Node = null;\n _indent: number = 0;\n _indentRepeat: number = 0;\n _insideAux: boolean = false;\n _noLineTerminator: boolean = false;\n _noLineTerminatorAfterNode: t.Node | null = null;\n _printAuxAfterOnNextUserNode: boolean = false;\n _printedComments = new Set<t.Comment>();\n _endsWithInteger = false;\n _endsWithWord = false;\n _endsWithDiv = false;\n _lastCommentLine = 0;\n _endsWithInnerRaw: boolean = false;\n _indentInnerComments: boolean = true;\n tokenMap: TokenMap = null;\n\n _boundGetRawIdentifier = this._getRawIdentifier.bind(this);\n\n generate(ast: t.Node) {\n if (this.format.preserveFormat) {\n this.tokenMap = new TokenMap(ast, this._tokens, this._originalCode);\n }\n this.print(ast);\n this._maybeAddAuxComment();\n\n return this._buf.get();\n }\n\n /**\n * Increment indent size.\n */\n\n indent(): void {\n const { format } = this;\n if (format.preserveFormat || format.compact || format.concise) {\n return;\n }\n\n this._indent++;\n }\n\n /**\n * Decrement indent size.\n */\n\n dedent(): void {\n const { format } = this;\n if (format.preserveFormat || format.compact || format.concise) {\n return;\n }\n\n this._indent--;\n }\n\n /**\n * Add a semicolon to the buffer.\n */\n\n semicolon(force: boolean = false): void {\n this._maybeAddAuxComment();\n if (force) {\n this._appendChar(charCodes.semicolon);\n this._noLineTerminator = false;\n return;\n }\n if (this.tokenMap) {\n const node = this._currentNode;\n if (node.start != null && node.end != null) {\n if (!this.tokenMap.endMatches(node, \";\")) {\n // no semicolon\n return;\n }\n const indexes = this.tokenMap.getIndexes(this._currentNode);\n this._catchUpTo(this._tokens[indexes[indexes.length - 1]].loc.start);\n }\n }\n this._queue(charCodes.semicolon);\n this._noLineTerminator = false;\n }\n\n /**\n * Add a right brace to the buffer.\n */\n\n rightBrace(node: t.Node): void {\n if (this.format.minified) {\n this._buf.removeLastSemicolon();\n }\n this.sourceWithOffset(\"end\", node.loc, -1);\n this.token(\"}\");\n }\n\n rightParens(node: t.Node): void {\n this.sourceWithOffset(\"end\", node.loc, -1);\n this.token(\")\");\n }\n\n /**\n * Add a space to the buffer unless it is compact.\n */\n\n space(force: boolean = false): void {\n const { format } = this;\n if (format.compact || format.preserveFormat) return;\n\n if (force) {\n this._space();\n } else if (this._buf.hasContent()) {\n const lastCp = this.getLastChar();\n if (lastCp !== charCodes.space && lastCp !== charCodes.lineFeed) {\n this._space();\n }\n }\n }\n\n /**\n * Writes a token that can't be safely parsed without taking whitespace into account.\n */\n\n word(str: string, noLineTerminatorAfter: boolean = false): void {\n this.tokenContext = 0;\n\n this._maybePrintInnerComments(str);\n\n // prevent concatenating words and creating // comment out of division and regex\n if (\n this._endsWithWord ||\n (this._endsWithDiv && str.charCodeAt(0) === charCodes.slash)\n ) {\n this._space();\n }\n\n this._maybeAddAuxComment();\n this._append(str, false);\n\n this._endsWithWord = true;\n this._noLineTerminator = noLineTerminatorAfter;\n }\n\n /**\n * Writes a number token so that we can validate if it is an integer.\n */\n\n number(str: string, number?: number): void {\n // const NON_DECIMAL_LITERAL = /^0[box]/;\n function isNonDecimalLiteral(str: string) {\n if (str.length > 2 && str.charCodeAt(0) === charCodes.digit0) {\n const secondChar = str.charCodeAt(1);\n return (\n secondChar === charCodes.lowercaseB ||\n secondChar === charCodes.lowercaseO ||\n secondChar === charCodes.lowercaseX\n );\n }\n return false;\n }\n this.word(str);\n\n // Integer tokens need special handling because they cannot have '.'s inserted\n // immediately after them.\n this._endsWithInteger =\n Number.isInteger(number) &&\n !isNonDecimalLiteral(str) &&\n !SCIENTIFIC_NOTATION.test(str) &&\n !ZERO_DECIMAL_INTEGER.test(str) &&\n str.charCodeAt(str.length - 1) !== charCodes.dot;\n }\n\n /**\n * Writes a simple token.\n *\n * @param {string} str The string to append.\n * @param {boolean} [maybeNewline=false] Wether `str` might potentially\n * contain a line terminator or not.\n * @param {number} [occurrenceCount=0] The occurrence count of this token in\n * the current node. This is used when printing in `preserveFormat` mode,\n * to know which token we should map to (for example, to disambiguate the\n * commas in an array literal).\n */\n token(str: string, maybeNewline = false, occurrenceCount = 0): void {\n this.tokenContext = 0;\n\n this._maybePrintInnerComments(str, occurrenceCount);\n\n const lastChar = this.getLastChar();\n const strFirst = str.charCodeAt(0);\n if (\n (lastChar === charCodes.exclamationMark &&\n // space is mandatory to avoid outputting <!--\n // http://javascript.spec.whatwg.org/#comment-syntax\n (str === \"--\" ||\n // Needs spaces to avoid changing a! == 0 to a!== 0\n strFirst === charCodes.equalsTo)) ||\n // Need spaces for operators of the same kind to avoid: `a+++b`\n (strFirst === charCodes.plusSign && lastChar === charCodes.plusSign) ||\n (strFirst === charCodes.dash && lastChar === charCodes.dash) ||\n // Needs spaces to avoid changing '34' to '34.', which would still be a valid number.\n (strFirst === charCodes.dot && this._endsWithInteger)\n ) {\n this._space();\n }\n\n this._maybeAddAuxComment();\n this._append(str, maybeNewline, occurrenceCount);\n this._noLineTerminator = false;\n }\n\n tokenChar(char: number): void {\n this.tokenContext = 0;\n\n this._maybePrintInnerComments(String.fromCharCode(char));\n\n const lastChar = this.getLastChar();\n if (\n // Need spaces for operators of the same kind to avoid: `a+++b`\n (char === charCodes.plusSign && lastChar === charCodes.plusSign) ||\n (char === charCodes.dash && lastChar === charCodes.dash) ||\n // Needs spaces to avoid changing '34' to '34.', which would still be a valid number.\n (char === charCodes.dot && this._endsWithInteger)\n ) {\n this._space();\n }\n\n this._maybeAddAuxComment();\n this._appendChar(char);\n this._noLineTerminator = false;\n }\n\n /**\n * Add a newline (or many newlines), maintaining formatting.\n * This function checks the number of newlines in the queue and subtracts them.\n * It currently has some limitations.\n * @see {Buffer#getNewlineCount}\n */\n newline(i: number = 1, force?: boolean): void {\n if (i <= 0) return;\n\n if (!force) {\n if (this.format.retainLines || this.format.compact) return;\n\n if (this.format.concise) {\n this.space();\n return;\n }\n }\n\n if (i > 2) i = 2; // Max two lines\n\n i -= this._buf.getNewlineCount();\n\n for (let j = 0; j < i; j++) {\n this._newline();\n }\n\n return;\n }\n\n endsWith(char: number): boolean {\n return this.getLastChar() === char;\n }\n\n getLastChar(): number {\n return this._buf.getLastChar();\n }\n\n endsWithCharAndNewline(): number {\n return this._buf.endsWithCharAndNewline();\n }\n\n removeTrailingNewline(): void {\n this._buf.removeTrailingNewline();\n }\n\n exactSource(loc: Loc | undefined, cb: () => void) {\n if (!loc) {\n cb();\n return;\n }\n\n this._catchUp(\"start\", loc);\n\n this._buf.exactSource(loc, cb);\n }\n\n source(prop: \"start\" | \"end\", loc: Loc | undefined): void {\n if (!loc) return;\n\n this._catchUp(prop, loc);\n\n this._buf.source(prop, loc);\n }\n\n sourceWithOffset(\n prop: \"start\" | \"end\",\n loc: Loc | undefined,\n columnOffset: number,\n ): void {\n if (!loc || this.format.preserveFormat) return;\n\n this._catchUp(prop, loc);\n\n this._buf.sourceWithOffset(prop, loc, columnOffset);\n }\n\n sourceIdentifierName(identifierName: string, pos?: Pos): void {\n if (!this._buf._canMarkIdName) return;\n\n const sourcePosition = this._buf._sourcePosition;\n sourcePosition.identifierNamePos = pos;\n sourcePosition.identifierName = identifierName;\n }\n\n _space(): void {\n this._queue(charCodes.space);\n }\n\n _newline(): void {\n this._queue(charCodes.lineFeed);\n }\n\n _append(\n str: string,\n maybeNewline: boolean,\n occurrenceCount: number = 0,\n ): void {\n if (this.tokenMap) {\n const token = this.tokenMap.findMatching(\n this._currentNode,\n str,\n occurrenceCount,\n );\n if (token) this._catchUpTo(token.loc.start);\n }\n\n this._maybeIndent(str.charCodeAt(0));\n\n this._buf.append(str, maybeNewline);\n\n // callers are expected to then set these to `true` when needed\n this._endsWithWord = false;\n this._endsWithInteger = false;\n this._endsWithDiv = false;\n }\n\n _appendChar(char: number): void {\n if (this.tokenMap) {\n const token = this.tokenMap.findMatching(\n this._currentNode,\n String.fromCharCode(char),\n );\n if (token) this._catchUpTo(token.loc.start);\n }\n\n this._maybeIndent(char);\n\n this._buf.appendChar(char);\n\n // callers are expected to then set these to `true` when needed\n this._endsWithWord = false;\n this._endsWithInteger = false;\n this._endsWithDiv = false;\n }\n\n _queue(char: number) {\n this._maybeIndent(char);\n\n this._buf.queue(char);\n\n this._endsWithWord = false;\n this._endsWithInteger = false;\n }\n\n _maybeIndent(firstChar: number): void {\n // we've got a newline before us so prepend on the indentation\n if (\n this._indent &&\n firstChar !== charCodes.lineFeed &&\n this.endsWith(charCodes.lineFeed)\n ) {\n this._buf.queueIndentation(this._getIndent());\n }\n }\n\n _shouldIndent(firstChar: number) {\n // we've got a newline before us so prepend on the indentation\n if (\n this._indent &&\n firstChar !== charCodes.lineFeed &&\n this.endsWith(charCodes.lineFeed)\n ) {\n return true;\n }\n }\n\n catchUp(line: number) {\n if (!this.format.retainLines) return;\n\n // catch up to this nodes newline if we're behind\n const count = line - this._buf.getCurrentLine();\n\n for (let i = 0; i < count; i++) {\n this._newline();\n }\n }\n\n _catchUp(prop: \"start\" | \"end\", loc?: Loc) {\n const { format } = this;\n if (!format.preserveFormat) {\n if (format.retainLines && loc?.[prop]) {\n this.catchUp(loc[prop].line);\n }\n return;\n }\n\n // catch up to this nodes newline if we're behind\n const pos = loc?.[prop];\n if (pos != null) this._catchUpTo(pos);\n }\n\n _catchUpTo({ line, column, index }: Pos) {\n const count = line - this._buf.getCurrentLine();\n if (count > 0 && this._noLineTerminator) {\n // We cannot inject new lines when _noLineTemrinator is set\n // to `true`, or we would generate invalid code.\n return;\n }\n\n for (let i = 0; i < count; i++) {\n this._newline();\n }\n\n const spacesCount =\n count > 0 ? column : column - this._buf.getCurrentColumn();\n if (spacesCount > 0) {\n const spaces = this._originalCode\n ? this._originalCode\n .slice(index - spacesCount, index)\n // https://tc39.es/ecma262/#sec-white-space\n .replace(/[^\\t\\v\\f\\uFEFF\\p{Space_Separator}]/gu, \" \")\n : \" \".repeat(spacesCount);\n this._append(spaces, false);\n }\n }\n\n /**\n * Get the current indent.\n */\n\n _getIndent(): number {\n return this._indentRepeat * this._indent;\n }\n\n printTerminatorless(node: t.Node) {\n /**\n * Set some state that will be modified if a newline has been inserted before any\n * non-space characters.\n *\n * This is to prevent breaking semantics for terminatorless separator nodes. eg:\n *\n * return foo;\n *\n * returns `foo`. But if we do:\n *\n * return\n * foo;\n *\n * `undefined` will be returned and not `foo` due to the terminator.\n */\n this._noLineTerminator = true;\n this.print(node);\n }\n\n print(\n node: t.Node | null,\n noLineTerminatorAfter?: boolean,\n // trailingCommentsLineOffset also used to check if called from printJoin\n // it will be ignored if `noLineTerminatorAfter||this._noLineTerminator`\n trailingCommentsLineOffset?: number,\n ) {\n if (!node) return;\n\n this._endsWithInnerRaw = false;\n\n const nodeType = node.type;\n const format = this.format;\n\n const oldConcise = format.concise;\n if (\n // @ts-expect-error document _compact AST properties\n node._compact\n ) {\n format.concise = true;\n }\n\n const printMethod =\n this[\n nodeType as Exclude<\n t.Node[\"type\"],\n // removed\n | \"Noop\"\n // renamed\n | t.DeprecatedAliases[\"type\"]\n >\n ];\n if (printMethod === undefined) {\n throw new ReferenceError(\n `unknown node of type ${JSON.stringify(\n nodeType,\n )} with constructor ${JSON.stringify(node.constructor.name)}`,\n );\n }\n\n const parent = this._currentNode;\n this._currentNode = node;\n\n const oldInAux = this._insideAux;\n this._insideAux = node.loc == null;\n this._maybeAddAuxComment(this._insideAux && !oldInAux);\n\n const parenthesized = node.extra?.parenthesized as boolean | undefined;\n let shouldPrintParens =\n (parenthesized && format.preserveFormat) ||\n (parenthesized &&\n format.retainFunctionParens &&\n nodeType === \"FunctionExpression\") ||\n needsParens(\n node,\n parent,\n this.tokenContext,\n this.inForStatementInit,\n format.preserveFormat ? this._boundGetRawIdentifier : undefined,\n );\n\n if (\n !shouldPrintParens &&\n parenthesized &&\n node.leadingComments?.length &&\n node.leadingComments[0].type === \"CommentBlock\"\n ) {\n const parentType = parent?.type;\n switch (parentType) {\n case \"ExpressionStatement\":\n case \"VariableDeclarator\":\n case \"AssignmentExpression\":\n case \"ReturnStatement\":\n break;\n case \"CallExpression\":\n case \"OptionalCallExpression\":\n case \"NewExpression\":\n if (parent.callee !== node) break;\n // falls through\n default:\n shouldPrintParens = true;\n }\n }\n\n let indentParenthesized = false;\n if (\n !shouldPrintParens &&\n this._noLineTerminator &&\n (node.leadingComments?.some(commentIsNewline) ||\n (this.format.retainLines &&\n node.loc &&\n node.loc.start.line > this._buf.getCurrentLine()))\n ) {\n shouldPrintParens = true;\n indentParenthesized = true;\n }\n\n let oldNoLineTerminatorAfterNode;\n let oldInForStatementInitWasTrue;\n if (!shouldPrintParens) {\n noLineTerminatorAfter ||=\n parent &&\n this._noLineTerminatorAfterNode === parent &&\n n.isLastChild(parent, node);\n if (noLineTerminatorAfter) {\n if (node.trailingComments?.some(commentIsNewline)) {\n if (isExpression(node)) shouldPrintParens = true;\n } else {\n oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n this._noLineTerminatorAfterNode = node;\n }\n }\n }\n\n if (shouldPrintParens) {\n this.token(\"(\");\n if (indentParenthesized) this.indent();\n this._endsWithInnerRaw = false;\n if (this.inForStatementInit) {\n oldInForStatementInitWasTrue = true;\n this.inForStatementInit = false;\n }\n oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n this._noLineTerminatorAfterNode = null;\n }\n\n this._lastCommentLine = 0;\n\n this._printLeadingComments(node, parent);\n\n const loc = nodeType === \"Program\" || nodeType === \"File\" ? null : node.loc;\n\n this.exactSource(\n loc,\n // @ts-expect-error Expected 1 arguments, but got 3.\n printMethod.bind(this, node, parent),\n );\n\n if (shouldPrintParens) {\n this._printTrailingComments(node, parent);\n if (indentParenthesized) {\n this.dedent();\n this.newline();\n }\n this.token(\")\");\n this._noLineTerminator = noLineTerminatorAfter;\n if (oldInForStatementInitWasTrue) this.inForStatementInit = true;\n } else if (noLineTerminatorAfter && !this._noLineTerminator) {\n this._noLineTerminator = true;\n this._printTrailingComments(node, parent);\n } else {\n this._printTrailingComments(node, parent, trailingCommentsLineOffset);\n }\n\n // end\n this._currentNode = parent;\n format.concise = oldConcise;\n this._insideAux = oldInAux;\n\n if (oldNoLineTerminatorAfterNode !== undefined) {\n this._noLineTerminatorAfterNode = oldNoLineTerminatorAfterNode;\n }\n\n this._endsWithInnerRaw = false;\n }\n\n _maybeAddAuxComment(enteredPositionlessNode?: boolean) {\n if (enteredPositionlessNode) this._printAuxBeforeComment();\n if (!this._insideAux) this._printAuxAfterComment();\n }\n\n _printAuxBeforeComment() {\n if (this._printAuxAfterOnNextUserNode) return;\n this._printAuxAfterOnNextUserNode = true;\n\n const comment = this.format.auxiliaryCommentBefore;\n if (comment) {\n this._printComment(\n {\n type: \"CommentBlock\",\n value: comment,\n },\n COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n }\n }\n\n _printAuxAfterComment() {\n if (!this._printAuxAfterOnNextUserNode) return;\n this._printAuxAfterOnNextUserNode = false;\n\n const comment = this.format.auxiliaryCommentAfter;\n if (comment) {\n this._printComment(\n {\n type: \"CommentBlock\",\n value: comment,\n },\n COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n }\n }\n\n getPossibleRaw(\n node:\n | t.StringLiteral\n | t.NumericLiteral\n | t.BigIntLiteral\n | t.DirectiveLiteral\n | t.JSXText,\n ): string | undefined {\n const extra = node.extra;\n if (\n extra?.raw != null &&\n extra.rawValue != null &&\n node.value === extra.rawValue\n ) {\n // @ts-expect-error: The extra.raw of these AST node types must be a string\n return extra.raw;\n }\n }\n\n printJoin(\n nodes: Array<t.Node> | undefined | null,\n opts: PrintJoinOptions = {},\n ) {\n if (!nodes?.length) return;\n\n let { indent } = opts;\n\n if (indent == null && this.format.retainLines) {\n const startLine = nodes[0].loc?.start.line;\n if (startLine != null && startLine !== this._buf.getCurrentLine()) {\n indent = true;\n }\n }\n\n if (indent) this.indent();\n\n const newlineOpts: AddNewlinesOptions = {\n addNewlines: opts.addNewlines,\n nextNodeStartLine: 0,\n };\n\n const separator = opts.separator ? opts.separator.bind(this) : null;\n\n const len = nodes.length;\n for (let i = 0; i < len; i++) {\n const node = nodes[i];\n if (!node) continue;\n\n if (opts.statement) this._printNewline(i === 0, newlineOpts);\n\n this.print(node, undefined, opts.trailingCommentsLineOffset || 0);\n\n opts.iterator?.(node, i);\n\n if (separator != null) {\n if (i < len - 1) separator(i, false);\n else if (opts.printTrailingSeparator) separator(i, true);\n }\n\n if (opts.statement) {\n if (!node.trailingComments?.length) {\n this._lastCommentLine = 0;\n }\n\n if (i + 1 === len) {\n this.newline(1);\n } else {\n const nextNode = nodes[i + 1];\n newlineOpts.nextNodeStartLine = nextNode.loc?.start.line || 0;\n\n this._printNewline(true, newlineOpts);\n }\n }\n }\n\n if (indent) this.dedent();\n }\n\n printAndIndentOnComments(node: t.Node) {\n const indent = node.leadingComments && node.leadingComments.length > 0;\n if (indent) this.indent();\n this.print(node);\n if (indent) this.dedent();\n }\n\n printBlock(parent: Extract<t.Node, { body: t.Statement }>) {\n const node = parent.body;\n\n if (node.type !== \"EmptyStatement\") {\n this.space();\n }\n\n this.print(node);\n }\n\n _printTrailingComments(node: t.Node, parent?: t.Node, lineOffset?: number) {\n const { innerComments, trailingComments } = node;\n // We print inner comments here, so that if for some reason they couldn't\n // be printed in earlier locations they are still printed *somewhere*,\n // even if at the end of the node.\n if (innerComments?.length) {\n this._printComments(\n COMMENT_TYPE.TRAILING,\n innerComments,\n node,\n parent,\n lineOffset,\n );\n }\n if (trailingComments?.length) {\n this._printComments(\n COMMENT_TYPE.TRAILING,\n trailingComments,\n node,\n parent,\n lineOffset,\n );\n }\n }\n\n _printLeadingComments(node: t.Node, parent: t.Node) {\n const comments = node.leadingComments;\n if (!comments?.length) return;\n this._printComments(COMMENT_TYPE.LEADING, comments, node, parent);\n }\n\n _maybePrintInnerComments(\n nextTokenStr: string,\n nextTokenOccurrenceCount?: number,\n ) {\n if (this._endsWithInnerRaw) {\n this.printInnerComments(\n this.tokenMap?.findMatching(\n this._currentNode,\n nextTokenStr,\n nextTokenOccurrenceCount,\n ),\n );\n }\n this._endsWithInnerRaw = true;\n this._indentInnerComments = true;\n }\n\n printInnerComments(nextToken?: Token) {\n const node = this._currentNode;\n const comments = node.innerComments;\n if (!comments?.length) return;\n\n const hasSpace = this.endsWith(charCodes.space);\n const indent = this._indentInnerComments;\n const printedCommentsCount = this._printedComments.size;\n if (indent) this.indent();\n this._printComments(\n COMMENT_TYPE.INNER,\n comments,\n node,\n undefined,\n undefined,\n nextToken,\n );\n if (hasSpace && printedCommentsCount !== this._printedComments.size) {\n this.space();\n }\n if (indent) this.dedent();\n }\n\n noIndentInnerCommentsHere() {\n this._indentInnerComments = false;\n }\n\n printSequence(nodes: t.Node[], opts: PrintSequenceOptions = {}) {\n opts.statement = true;\n opts.indent ??= false;\n this.printJoin(nodes, opts);\n }\n\n printList(items: t.Node[], opts: PrintListOptions = {}) {\n if (opts.separator == null) {\n opts.separator = commaSeparator;\n }\n\n this.printJoin(items, opts);\n }\n\n shouldPrintTrailingComma(listEnd: string): boolean | null {\n if (!this.tokenMap) return null;\n\n const listEndIndex = this.tokenMap.findLastIndex(this._currentNode, token =>\n this.tokenMap.matchesOriginal(token, listEnd),\n );\n if (listEndIndex <= 0) return null;\n return this.tokenMap.matchesOriginal(this._tokens[listEndIndex - 1], \",\");\n }\n\n _printNewline(newLine: boolean, opts: AddNewlinesOptions) {\n const format = this.format;\n\n // Fast path since 'this.newline' does nothing when not tracking lines.\n if (format.retainLines || format.compact) return;\n\n // Fast path for concise since 'this.newline' just inserts a space when\n // concise formatting is in use.\n if (format.concise) {\n this.space();\n return;\n }\n\n if (!newLine) {\n return;\n }\n\n const startLine = opts.nextNodeStartLine;\n const lastCommentLine = this._lastCommentLine;\n if (startLine > 0 && lastCommentLine > 0) {\n const offset = startLine - lastCommentLine;\n if (offset >= 0) {\n this.newline(offset || 1);\n return;\n }\n }\n\n // don't add newlines at the beginning of the file\n if (this._buf.hasContent()) {\n // Here is the logic of the original line wrapping according to the node layout, we are not using it now.\n // We currently add at most one newline to each node in the list, ignoring `opts.addNewlines`.\n\n // let lines = 0;\n // if (!leading) lines++; // always include at least a single line after\n // if (opts.addNewlines) lines += opts.addNewlines(leading, node) || 0;\n\n // const needs = leading ? needsWhitespaceBefore : needsWhitespaceAfter;\n // if (needs(node, parent)) lines++;\n\n // this.newline(Math.min(2, lines));\n\n this.newline(1);\n }\n }\n\n // Returns `PRINT_COMMENT_HINT.DEFER` if the comment cannot be printed in this position due to\n // line terminators, signaling that the print comments loop can stop and\n // resume printing comments at the next possible position. This happens when\n // printing inner comments, since if we have an inner comment with a multiline\n // there is at least one inner position where line terminators are allowed.\n _shouldPrintComment(\n comment: t.Comment,\n nextToken?: Token,\n ): PRINT_COMMENT_HINT {\n // Some plugins (such as flow-strip-types) use this to mark comments as removed using the AST-root 'comments' property,\n // where they can't manually mutate the AST node comment lists.\n if (comment.ignore) return PRINT_COMMENT_HINT.SKIP;\n\n if (this._printedComments.has(comment)) return PRINT_COMMENT_HINT.SKIP;\n\n if (\n this._noLineTerminator &&\n HAS_NEWLINE_OR_BlOCK_COMMENT_END.test(comment.value)\n ) {\n return PRINT_COMMENT_HINT.DEFER;\n }\n\n if (nextToken && this.tokenMap) {\n const commentTok = this.tokenMap.find(\n this._currentNode,\n token => token.value === comment.value,\n );\n if (commentTok && commentTok.start > nextToken.start) {\n return PRINT_COMMENT_HINT.DEFER;\n }\n }\n\n this._printedComments.add(comment);\n\n if (!this.format.shouldPrintComment(comment.value)) {\n return PRINT_COMMENT_HINT.SKIP;\n }\n\n return PRINT_COMMENT_HINT.ALLOW;\n }\n\n _printComment(comment: t.Comment, skipNewLines: COMMENT_SKIP_NEWLINE) {\n const noLineTerminator = this._noLineTerminator;\n const isBlockComment = comment.type === \"CommentBlock\";\n\n // Add a newline before and after a block comment, unless explicitly\n // disallowed\n const printNewLines =\n isBlockComment &&\n skipNewLines !== COMMENT_SKIP_NEWLINE.ALL &&\n !this._noLineTerminator;\n\n if (\n printNewLines &&\n this._buf.hasContent() &&\n skipNewLines !== COMMENT_SKIP_NEWLINE.LEADING\n ) {\n this.newline(1);\n }\n\n const lastCharCode = this.getLastChar();\n if (\n lastCharCode !== charCodes.leftSquareBracket &&\n lastCharCode !== charCodes.leftCurlyBrace &&\n lastCharCode !== charCodes.leftParenthesis\n ) {\n this.space();\n }\n\n let val;\n if (isBlockComment) {\n val = `/*${comment.value}*/`;\n if (this.format.indent.adjustMultilineComment) {\n const offset = comment.loc?.start.column;\n if (offset) {\n const newlineRegex = new RegExp(\"\\\\n\\\\s{1,\" + offset + \"}\", \"g\");\n val = val.replace(newlineRegex, \"\\n\");\n }\n if (this.format.concise) {\n val = val.replace(/\\n(?!$)/g, `\\n`);\n } else {\n let indentSize = this.format.retainLines\n ? 0\n : this._buf.getCurrentColumn();\n\n if (this._shouldIndent(charCodes.slash) || this.format.retainLines) {\n indentSize += this._getIndent();\n }\n\n val = val.replace(/\\n(?!$)/g, `\\n${\" \".repeat(indentSize)}`);\n }\n }\n } else if (!noLineTerminator) {\n val = `//${comment.value}`;\n } else {\n // It was a single-line comment, so it's guaranteed to not\n // contain newlines and it can be safely printed as a block\n // comment.\n val = `/*${comment.value}*/`;\n }\n\n // Avoid converting a / operator into a line comment by appending /* to it\n if (this._endsWithDiv) this._space();\n\n this.source(\"start\", comment.loc);\n this._append(val, isBlockComment);\n\n if (!isBlockComment && !noLineTerminator) {\n this.newline(1, true);\n }\n\n if (printNewLines && skipNewLines !== COMMENT_SKIP_NEWLINE.TRAILING) {\n this.newline(1);\n }\n }\n\n _printComments(\n type: COMMENT_TYPE,\n comments: readonly t.Comment[],\n node: t.Node,\n parent?: t.Node,\n lineOffset: number = 0,\n nextToken?: Token,\n ) {\n const nodeLoc = node.loc;\n const len = comments.length;\n let hasLoc = !!nodeLoc;\n const nodeStartLine = hasLoc ? nodeLoc.start.line : 0;\n const nodeEndLine = hasLoc ? nodeLoc.end.line : 0;\n let lastLine = 0;\n let leadingCommentNewline = 0;\n\n const maybeNewline = this._noLineTerminator\n ? function () {}\n : this.newline.bind(this);\n\n for (let i = 0; i < len; i++) {\n const comment = comments[i];\n\n const shouldPrint = this._shouldPrintComment(comment, nextToken);\n if (shouldPrint === PRINT_COMMENT_HINT.DEFER) {\n hasLoc = false;\n break;\n }\n if (hasLoc && comment.loc && shouldPrint === PRINT_COMMENT_HINT.ALLOW) {\n const commentStartLine = comment.loc.start.line;\n const commentEndLine = comment.loc.end.line;\n if (type === COMMENT_TYPE.LEADING) {\n let offset = 0;\n if (i === 0) {\n // Because currently we cannot handle blank lines before leading comments,\n // we always wrap before and after multi-line comments.\n if (\n this._buf.hasContent() &&\n (comment.type === \"CommentLine\" ||\n commentStartLine !== commentEndLine)\n ) {\n offset = leadingCommentNewline = 1;\n }\n } else {\n offset = commentStartLine - lastLine;\n }\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n\n if (i + 1 === len) {\n maybeNewline(\n Math.max(nodeStartLine - lastLine, leadingCommentNewline),\n );\n lastLine = nodeStartLine;\n }\n } else if (type === COMMENT_TYPE.INNER) {\n const offset =\n commentStartLine - (i === 0 ? nodeStartLine : lastLine);\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n\n if (i + 1 === len) {\n maybeNewline(Math.min(1, nodeEndLine - lastLine)); // TODO: Improve here when inner comments processing is stronger\n lastLine = nodeEndLine;\n }\n } else {\n const offset =\n commentStartLine - (i === 0 ? nodeEndLine - lineOffset : lastLine);\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n }\n } else {\n hasLoc = false;\n if (shouldPrint !== PRINT_COMMENT_HINT.ALLOW) {\n continue;\n }\n\n if (len === 1) {\n const singleLine = comment.loc\n ? comment.loc.start.line === comment.loc.end.line\n : !HAS_NEWLINE.test(comment.value);\n\n const shouldSkipNewline =\n singleLine &&\n !isStatement(node) &&\n !isClassBody(parent) &&\n !isTSInterfaceBody(parent) &&\n !isTSEnumDeclaration(parent);\n\n if (type === COMMENT_TYPE.LEADING) {\n this._printComment(\n comment,\n (shouldSkipNewline && node.type !== \"ObjectExpression\") ||\n (singleLine && isFunction(parent, { body: node }))\n ? COMMENT_SKIP_NEWLINE.ALL\n : COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n } else if (shouldSkipNewline && type === COMMENT_TYPE.TRAILING) {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n } else {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.DEFAULT);\n }\n } else if (\n type === COMMENT_TYPE.INNER &&\n !(node.type === \"ObjectExpression\" && node.properties.length > 1) &&\n node.type !== \"ClassBody\" &&\n node.type !== \"TSInterfaceBody\"\n ) {\n // class X {\n // /*:: a: number*/\n // /*:: b: ?string*/\n // }\n\n this._printComment(\n comment,\n i === 0\n ? COMMENT_SKIP_NEWLINE.LEADING\n : i === len - 1\n ? COMMENT_SKIP_NEWLINE.TRAILING\n : COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n } else {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.DEFAULT);\n }\n }\n }\n\n if (type === COMMENT_TYPE.TRAILING && hasLoc && lastLine) {\n this._lastCommentLine = lastLine;\n }\n }\n}\n\n// Expose the node type functions and helpers on the prototype for easy usage.\nObject.assign(Printer.prototype, generatorFunctions);\n\nif (!process.env.BABEL_8_BREAKING) {\n // @ts-ignore(Babel 7 vs Babel 8) Babel 7 has Noop print method\n Printer.prototype.Noop = function Noop(this: Printer) {};\n}\n\ntype GeneratorFunctions = typeof generatorFunctions;\n// eslint-disable-next-line @typescript-eslint/no-empty-object-type\ninterface Printer extends GeneratorFunctions {}\nexport default Printer;\n\nfunction commaSeparator(this: Printer, occurrenceCount: number, last: boolean) {\n this.token(\",\", false, occurrenceCount);\n if (!last) this.space();\n}\n"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAEA,IAAAC,CAAA,GAAAD,OAAA;AAEA,IAAAE,EAAA,GAAAF,OAAA;AAUA,IAAAG,SAAA,GAAAH,OAAA;AAEA,IAAAI,kBAAA,GAAAJ,OAAA;AAA4D;EAX1DK,YAAY;EACZC,UAAU;EACVC,WAAW;EACXC,WAAW;EAC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Q,OAAO;AAEtB,SAASoN,cAAcA,CAAgBhI,eAAuB,EAAEiL,IAAa,EAAE;EAC7E,IAAI,CAACpM,KAAK,CAAC,GAAG,EAAE,KAAK,EAAEmB,eAAe,CAAC;EACvC,IAAI,CAACiL,IAAI,EAAE,IAAI,CAAClM,KAAK,CAAC,CAAC;AACzB","ignoreList":[]}1 {"version":3,"names":["_buffer","require","n","_t","_tokenMap","generatorFunctions","_deprecated","isExpression","isFunction","isStatement","isClassBody","isTSInterfaceBody","isTSEnumMember","SCIENTIFIC_NOTATION","ZERO_DECIMAL_INTEGER","HAS_NEWLINE","HAS_NEWLINE_OR_BlOCK_COMMENT_END","commentIsNewline","c","type","test","value","needsParens","Printer","constructor","format","map","tokens","originalCode","inForStatementInit","tokenContext","_tokens","_originalCode","_currentNode","_indent","_indentRepeat","_insideAux","_noLineTerminator","_noLineTerminatorAfterNode","_printAuxAfterOnNextUserNode","_printedComments","Set","_endsWithInteger","_endsWithWord","_endsWithDiv","_lastCommentLine","_endsWithInnerRaw","_indentInnerComments","tokenMap","_boundGetRawIdentifier","_getRawIdentifier","bind","_printSemicolonBeforeNextNode","_printSemicolonBeforeNextToken","indent","style","length","_inputMap","_buf","Buffer","enterForStatementInit","enterDelimited","oldInForStatementInit","oldNoLineTerminatorAfterNode","generate","ast","preserveFormat","TokenMap","print","_maybeAddAuxComment","get","compact","concise","dedent","semicolon","force","_appendChar","node","start","end","endMatches","getCurrentLine","indexes","getIndexes","_catchUpTo","loc","_queue","rightBrace","minified","removeLastSemicolon","sourceWithOffset","token","rightParens","space","_space","hasContent","lastCp","getLastChar","word","str","noLineTerminatorAfter","_maybePrintInnerComments","_catchUpToCurrentToken","charCodeAt","_append","number","isNonDecimalLiteral","secondChar","Number","isInteger","maybeNewline","occurrenceCount","lastChar","strFirst","tokenChar","char","String","fromCharCode","newline","i","retainLines","getNewlineCount","j","_newline","endsWith","endsWithCharAndNewline","removeTrailingNewline","exactSource","cb","_catchUp","source","prop","columnOffset","sourceIdentifierName","identifierName","pos","_canMarkIdName","sourcePosition","_sourcePosition","identifierNamePos","findMatching","appendChar","_maybeIndent","append","queue","firstChar","queueIndentation","_getIndent","_shouldIndent","catchUp","line","count","column","index","spacesCount","getCurrentColumn","spaces","slice","replace","repeat","printTerminatorless","trailingCommentsLineOffset","_node$extra","_node$leadingComments","_node$leadingComments2","nodeType","oldConcise","_compact","printMethod","undefined","ReferenceError","JSON","stringify","name","parent","oldInAux","parenthesized","extra","shouldPrintParens","retainFunctionParens","leadingComments","parentType","callee","indentParenthesized","some","oldInForStatementInitWasTrue","isLastChild","_node$trailingComment","trailingComments","_printLeadingComments","_printTrailingComments","enteredPositionlessNode","_printAuxBeforeComment","_printAuxAfterComment","comment","auxiliaryCommentBefore","_printComment","auxiliaryCommentAfter","getPossibleRaw","raw","rawValue","printJoin","nodes","statement","separator","printTrailingSeparator","addNewlines","iterator","_nodes$0$loc","startLine","newlineOpts","nextNodeStartLine","boundSeparator","len","_printNewline","_node$trailingComment2","_nextNode$loc","nextNode","printAndIndentOnComments","printBlock","body","lineOffset","innerComments","_printComments","comments","nextTokenStr","nextTokenOccurrenceCount","_this$tokenMap","printInnerComments","nextToken","hasSpace","printedCommentsCount","size","noIndentInnerCommentsHere","printSequence","printList","items","commaSeparator","shouldPrintTrailingComma","listEnd","listEndIndex","findLastIndex","matchesOriginal","newLine","opts","lastCommentLine","offset","_shouldPrintComment","ignore","has","commentTok","find","add","shouldPrintComment","skipNewLines","noLineTerminator","isBlockComment","printNewLines","lastCharCode","val","adjustMultilineComment","_comment$loc","newlineRegex","RegExp","indentSize","nodeLoc","hasLoc","nodeStartLine","nodeEndLine","lastLine","leadingCommentNewline","shouldPrint","commentStartLine","commentEndLine","Math","max","min","singleLine","shouldSkipNewline","properties","Object","assign","prototype","addDeprecatedGenerators","_default","exports","default","last"],"sources":["../src/printer.ts"],"sourcesContent":["import Buffer, { type Pos } from \"./buffer.ts\";\nimport type { Loc } from \"./buffer.ts\";\nimport * as n from \"./node/index.ts\";\nimport type * as t from \"@babel/types\";\nimport {\n isExpression,\n isFunction,\n isStatement,\n isClassBody,\n isTSInterfaceBody,\n isTSEnumMember,\n} from \"@babel/types\";\nimport type { Opts as jsescOptions } from \"jsesc\";\n\nimport { TokenMap } from \"./token-map.ts\";\nimport type { GeneratorOptions } from \"./index.ts\";\nimport * as generatorFunctions from \"./generators/index.ts\";\nimport {\n addDeprecatedGenerators,\n type DeprecatedBabel7ASTTypes,\n} from \"./generators/deprecated.ts\";\nimport type SourceMap from \"./source-map.ts\";\nimport type { TraceMap } from \"@jridgewell/trace-mapping\";\nimport type { Token } from \"@babel/parser\";\n\n// We inline this package\n// eslint-disable-next-line import/no-extraneous-dependencies\nimport * as charCodes from \"charcodes\";\n\nconst SCIENTIFIC_NOTATION = /e/i;\nconst ZERO_DECIMAL_INTEGER = /\\.0+$/;\nconst HAS_NEWLINE = /[\\n\\r\\u2028\\u2029]/;\nconst HAS_NEWLINE_OR_BlOCK_COMMENT_END = /[\\n\\r\\u2028\\u2029]|\\*\\//;\n\nfunction commentIsNewline(c: t.Comment) {\n return c.type === \"CommentLine\" || HAS_NEWLINE.test(c.value);\n}\n\nconst { needsParens } = n;\n\nconst enum COMMENT_TYPE {\n LEADING,\n INNER,\n TRAILING,\n}\n\nconst enum COMMENT_SKIP_NEWLINE {\n DEFAULT,\n ALL,\n LEADING,\n TRAILING,\n}\n\nconst enum PRINT_COMMENT_HINT {\n SKIP,\n ALLOW,\n DEFER,\n}\n\nexport type Format = {\n shouldPrintComment: (comment: string) => boolean;\n preserveFormat: boolean;\n retainLines: boolean;\n retainFunctionParens: boolean;\n comments: boolean;\n auxiliaryCommentBefore: string;\n auxiliaryCommentAfter: string;\n compact: boolean | \"auto\";\n minified: boolean;\n concise: boolean;\n indent: {\n adjustMultilineComment: boolean;\n style: string;\n };\n /**\n * @deprecated Removed in Babel 8, syntax type is always 'hash'\n */\n recordAndTupleSyntaxType?: GeneratorOptions[\"recordAndTupleSyntaxType\"];\n jsescOption: jsescOptions;\n /**\n * @deprecated Removed in Babel 8, use `jsescOption` instead\n */\n jsonCompatibleStrings?: boolean;\n /**\n * For use with the Hack-style pipe operator.\n * Changes what token is used for pipe bodies’ topic references.\n */\n topicToken?: GeneratorOptions[\"topicToken\"];\n /**\n * @deprecated Removed in Babel 8\n */\n decoratorsBeforeExport?: boolean;\n /**\n * The import attributes syntax style:\n * - \"with\" : `import { a } from \"b\" with { type: \"json\" };`\n * - \"assert\" : `import { a } from \"b\" assert { type: \"json\" };`\n * - \"with-legacy\" : `import { a } from \"b\" with type: \"json\";`\n */\n importAttributesKeyword?: \"with\" | \"assert\" | \"with-legacy\";\n};\n\ninterface AddNewlinesOptions {\n addNewlines(leading: boolean, node: t.Node): number;\n nextNodeStartLine: number;\n}\n\ninterface PrintSequenceOptions extends Partial<AddNewlinesOptions> {\n statement?: boolean;\n indent?: boolean;\n trailingCommentsLineOffset?: number;\n}\n\ninterface PrintListOptions {\n separator?: (this: Printer, occurrenceCount: number, last: boolean) => void;\n iterator?: (node: t.Node, index: number) => void;\n statement?: boolean;\n indent?: boolean;\n printTrailingSeparator?: boolean;\n}\n\nexport type PrintJoinOptions = PrintListOptions & PrintSequenceOptions;\nclass Printer {\n constructor(\n format: Format,\n map: SourceMap,\n tokens?: Token[],\n originalCode?: string,\n ) {\n this.format = format;\n\n this._tokens = tokens;\n this._originalCode = originalCode;\n\n this._indentRepeat = format.indent.style.length;\n\n this._inputMap = map?._inputMap;\n\n this._buf = new Buffer(map, format.indent.style[0]);\n }\n declare _inputMap: TraceMap;\n\n declare format: Format;\n\n inForStatementInit: boolean = false;\n enterForStatementInit() {\n if (this.inForStatementInit) return () => {};\n this.inForStatementInit = true;\n return () => {\n this.inForStatementInit = false;\n };\n }\n\n enterDelimited() {\n const oldInForStatementInit = this.inForStatementInit;\n const oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n if (\n oldInForStatementInit === false &&\n oldNoLineTerminatorAfterNode === null\n ) {\n return () => {};\n }\n this.inForStatementInit = false;\n this._noLineTerminatorAfterNode = null;\n return () => {\n this.inForStatementInit = oldInForStatementInit;\n this._noLineTerminatorAfterNode = oldNoLineTerminatorAfterNode;\n };\n }\n\n tokenContext: number = 0;\n\n _tokens: Token[] = null;\n _originalCode: string | null = null;\n\n declare _buf: Buffer;\n _currentNode: t.Node = null;\n _indent: number = 0;\n _indentRepeat: number = 0;\n _insideAux: boolean = false;\n _noLineTerminator: boolean = false;\n _noLineTerminatorAfterNode: t.Node | null = null;\n _printAuxAfterOnNextUserNode: boolean = false;\n _printedComments = new Set<t.Comment>();\n _endsWithInteger = false;\n _endsWithWord = false;\n _endsWithDiv = false;\n _lastCommentLine = 0;\n _endsWithInnerRaw: boolean = false;\n _indentInnerComments: boolean = true;\n tokenMap: TokenMap = null;\n\n _boundGetRawIdentifier = this._getRawIdentifier.bind(this);\n\n generate(ast: t.Node) {\n if (this.format.preserveFormat) {\n this.tokenMap = new TokenMap(ast, this._tokens, this._originalCode);\n }\n this.print(ast);\n this._maybeAddAuxComment();\n\n return this._buf.get();\n }\n\n /**\n * Increment indent size.\n */\n\n indent(): void {\n const { format } = this;\n if (format.preserveFormat || format.compact || format.concise) {\n return;\n }\n\n this._indent++;\n }\n\n /**\n * Decrement indent size.\n */\n\n dedent(): void {\n const { format } = this;\n if (format.preserveFormat || format.compact || format.concise) {\n return;\n }\n\n this._indent--;\n }\n\n /**\n * If the next token is on the same line, we must first print a semicolon.\n * This option is only used in `preserveFormat` node, for semicolons that\n * might have omitted due to them being absent in the original code (thanks\n * to ASI).\n *\n * We need both *NextToken and *NextNode because we only want to insert the\n * semicolon when the next token starts a new node, and not in cases like\n * foo} (where } is not starting a new node). So we first set *NextNode, and\n * then the print() method will move it to *NextToken.\n */\n _printSemicolonBeforeNextNode: number = -1;\n _printSemicolonBeforeNextToken: number = -1;\n\n /**\n * Add a semicolon to the buffer.\n */\n semicolon(force: boolean = false): void {\n this._maybeAddAuxComment();\n if (force) {\n this._appendChar(charCodes.semicolon);\n this._noLineTerminator = false;\n return;\n }\n if (this.tokenMap) {\n const node = this._currentNode;\n if (node.start != null && node.end != null) {\n if (!this.tokenMap.endMatches(node, \";\")) {\n // no semicolon\n this._printSemicolonBeforeNextNode = this._buf.getCurrentLine();\n return;\n }\n const indexes = this.tokenMap.getIndexes(this._currentNode);\n this._catchUpTo(this._tokens[indexes[indexes.length - 1]].loc.start);\n }\n }\n this._queue(charCodes.semicolon);\n this._noLineTerminator = false;\n }\n\n /**\n * Add a right brace to the buffer.\n */\n\n rightBrace(node: t.Node): void {\n if (this.format.minified) {\n this._buf.removeLastSemicolon();\n }\n this.sourceWithOffset(\"end\", node.loc, -1);\n this.token(\"}\");\n }\n\n rightParens(node: t.Node): void {\n this.sourceWithOffset(\"end\", node.loc, -1);\n this.token(\")\");\n }\n\n /**\n * Add a space to the buffer unless it is compact.\n */\n\n space(force: boolean = false): void {\n const { format } = this;\n if (format.compact || format.preserveFormat) return;\n\n if (force) {\n this._space();\n } else if (this._buf.hasContent()) {\n const lastCp = this.getLastChar();\n if (lastCp !== charCodes.space && lastCp !== charCodes.lineFeed) {\n this._space();\n }\n }\n }\n\n /**\n * Writes a token that can't be safely parsed without taking whitespace into account.\n */\n\n word(str: string, noLineTerminatorAfter: boolean = false): void {\n this.tokenContext = 0;\n\n this._maybePrintInnerComments(str);\n\n this._maybeAddAuxComment();\n\n if (this.tokenMap) this._catchUpToCurrentToken(str);\n\n // prevent concatenating words and creating // comment out of division and regex\n if (\n this._endsWithWord ||\n (this._endsWithDiv && str.charCodeAt(0) === charCodes.slash)\n ) {\n this._space();\n }\n this._append(str, false);\n\n this._endsWithWord = true;\n this._noLineTerminator = noLineTerminatorAfter;\n }\n\n /**\n * Writes a number token so that we can validate if it is an integer.\n */\n\n number(str: string, number?: number): void {\n // const NON_DECIMAL_LITERAL = /^0[box]/;\n function isNonDecimalLiteral(str: string) {\n if (str.length > 2 && str.charCodeAt(0) === charCodes.digit0) {\n const secondChar = str.charCodeAt(1);\n return (\n secondChar === charCodes.lowercaseB ||\n secondChar === charCodes.lowercaseO ||\n secondChar === charCodes.lowercaseX\n );\n }\n return false;\n }\n this.word(str);\n\n // Integer tokens need special handling because they cannot have '.'s inserted\n // immediately after them.\n this._endsWithInteger =\n Number.isInteger(number) &&\n !isNonDecimalLiteral(str) &&\n !SCIENTIFIC_NOTATION.test(str) &&\n !ZERO_DECIMAL_INTEGER.test(str) &&\n str.charCodeAt(str.length - 1) !== charCodes.dot;\n }\n\n /**\n * Writes a simple token.\n *\n * @param {string} str The string to append.\n * @param {boolean} [maybeNewline=false] Wether `str` might potentially\n * contain a line terminator or not.\n * @param {number} [occurrenceCount=0] The occurrence count of this token in\n * the current node. This is used when printing in `preserveFormat` mode,\n * to know which token we should map to (for example, to disambiguate the\n * commas in an array literal).\n */\n token(str: string, maybeNewline = false, occurrenceCount = 0): void {\n this.tokenContext = 0;\n\n this._maybePrintInnerComments(str, occurrenceCount);\n\n this._maybeAddAuxComment();\n\n if (this.tokenMap) this._catchUpToCurrentToken(str, occurrenceCount);\n\n const lastChar = this.getLastChar();\n const strFirst = str.charCodeAt(0);\n if (\n (lastChar === charCodes.exclamationMark &&\n // space is mandatory to avoid outputting <!--\n // http://javascript.spec.whatwg.org/#comment-syntax\n (str === \"--\" ||\n // Needs spaces to avoid changing a! == 0 to a!== 0\n strFirst === charCodes.equalsTo)) ||\n // Need spaces for operators of the same kind to avoid: `a+++b`\n (strFirst === charCodes.plusSign && lastChar === charCodes.plusSign) ||\n (strFirst === charCodes.dash && lastChar === charCodes.dash) ||\n // Needs spaces to avoid changing '34' to '34.', which would still be a valid number.\n (strFirst === charCodes.dot && this._endsWithInteger)\n ) {\n this._space();\n }\n this._append(str, maybeNewline);\n this._noLineTerminator = false;\n }\n\n tokenChar(char: number): void {\n this.tokenContext = 0;\n\n const str = String.fromCharCode(char);\n this._maybePrintInnerComments(str);\n\n this._maybeAddAuxComment();\n\n if (this.tokenMap) this._catchUpToCurrentToken(str);\n\n const lastChar = this.getLastChar();\n if (\n // Need spaces for operators of the same kind to avoid: `a+++b`\n (char === charCodes.plusSign && lastChar === charCodes.plusSign) ||\n (char === charCodes.dash && lastChar === charCodes.dash) ||\n // Needs spaces to avoid changing '34' to '34.', which would still be a valid number.\n (char === charCodes.dot && this._endsWithInteger)\n ) {\n this._space();\n }\n this._appendChar(char);\n this._noLineTerminator = false;\n }\n\n /**\n * Add a newline (or many newlines), maintaining formatting.\n * This function checks the number of newlines in the queue and subtracts them.\n * It currently has some limitations.\n * @see {Buffer#getNewlineCount}\n */\n newline(i: number = 1, force?: boolean): void {\n if (i <= 0) return;\n\n if (!force) {\n if (this.format.retainLines || this.format.compact) return;\n\n if (this.format.concise) {\n this.space();\n return;\n }\n }\n\n if (i > 2) i = 2; // Max two lines\n\n i -= this._buf.getNewlineCount();\n\n for (let j = 0; j < i; j++) {\n this._newline();\n }\n\n return;\n }\n\n endsWith(char: number): boolean {\n return this.getLastChar() === char;\n }\n\n getLastChar(): number {\n return this._buf.getLastChar();\n }\n\n endsWithCharAndNewline(): number {\n return this._buf.endsWithCharAndNewline();\n }\n\n removeTrailingNewline(): void {\n this._buf.removeTrailingNewline();\n }\n\n exactSource(loc: Loc | undefined, cb: () => void) {\n if (!loc) {\n cb();\n return;\n }\n\n this._catchUp(\"start\", loc);\n\n this._buf.exactSource(loc, cb);\n }\n\n source(prop: \"start\" | \"end\", loc: Loc | undefined): void {\n if (!loc) return;\n\n this._catchUp(prop, loc);\n\n this._buf.source(prop, loc);\n }\n\n sourceWithOffset(\n prop: \"start\" | \"end\",\n loc: Loc | undefined,\n columnOffset: number,\n ): void {\n if (!loc || this.format.preserveFormat) return;\n\n this._catchUp(prop, loc);\n\n this._buf.sourceWithOffset(prop, loc, columnOffset);\n }\n\n sourceIdentifierName(identifierName: string, pos?: Pos): void {\n if (!this._buf._canMarkIdName) return;\n\n const sourcePosition = this._buf._sourcePosition;\n sourcePosition.identifierNamePos = pos;\n sourcePosition.identifierName = identifierName;\n }\n\n _space(): void {\n this._queue(charCodes.space);\n }\n\n _newline(): void {\n this._queue(charCodes.lineFeed);\n }\n\n _catchUpToCurrentToken(str: string, occurrenceCount: number = 0): void {\n // Assert: this.tokenMap\n\n const token = this.tokenMap.findMatching(\n this._currentNode,\n str,\n occurrenceCount,\n );\n if (token) this._catchUpTo(token.loc.start);\n\n if (\n this._printSemicolonBeforeNextToken !== -1 &&\n this._printSemicolonBeforeNextToken === this._buf.getCurrentLine()\n ) {\n this._buf.appendChar(charCodes.semicolon);\n this._endsWithWord = false;\n this._endsWithInteger = false;\n this._endsWithDiv = false;\n }\n this._printSemicolonBeforeNextToken = -1;\n this._printSemicolonBeforeNextNode = -1;\n }\n\n _append(str: string, maybeNewline: boolean): void {\n this._maybeIndent(str.charCodeAt(0));\n\n this._buf.append(str, maybeNewline);\n\n // callers are expected to then set these to `true` when needed\n this._endsWithWord = false;\n this._endsWithInteger = false;\n this._endsWithDiv = false;\n }\n\n _appendChar(char: number): void {\n this._maybeIndent(char);\n\n this._buf.appendChar(char);\n\n // callers are expected to then set these to `true` when needed\n this._endsWithWord = false;\n this._endsWithInteger = false;\n this._endsWithDiv = false;\n }\n\n _queue(char: number) {\n this._maybeIndent(char);\n\n this._buf.queue(char);\n\n this._endsWithWord = false;\n this._endsWithInteger = false;\n }\n\n _maybeIndent(firstChar: number): void {\n // we've got a newline before us so prepend on the indentation\n if (\n this._indent &&\n firstChar !== charCodes.lineFeed &&\n this.endsWith(charCodes.lineFeed)\n ) {\n this._buf.queueIndentation(this._getIndent());\n }\n }\n\n _shouldIndent(firstChar: number) {\n // we've got a newline before us so prepend on the indentation\n if (\n this._indent &&\n firstChar !== charCodes.lineFeed &&\n this.endsWith(charCodes.lineFeed)\n ) {\n return true;\n }\n }\n\n catchUp(line: number) {\n if (!this.format.retainLines) return;\n\n // catch up to this nodes newline if we're behind\n const count = line - this._buf.getCurrentLine();\n\n for (let i = 0; i < count; i++) {\n this._newline();\n }\n }\n\n _catchUp(prop: \"start\" | \"end\", loc?: Loc) {\n const { format } = this;\n if (!format.preserveFormat) {\n if (format.retainLines && loc?.[prop]) {\n this.catchUp(loc[prop].line);\n }\n return;\n }\n\n // catch up to this nodes newline if we're behind\n const pos = loc?.[prop];\n if (pos != null) this._catchUpTo(pos);\n }\n\n _catchUpTo({ line, column, index }: Pos) {\n const count = line - this._buf.getCurrentLine();\n if (count > 0 && this._noLineTerminator) {\n // We cannot inject new lines when _noLineTemrinator is set\n // to `true`, or we would generate invalid code.\n return;\n }\n\n for (let i = 0; i < count; i++) {\n this._newline();\n }\n\n const spacesCount =\n count > 0 ? column : column - this._buf.getCurrentColumn();\n if (spacesCount > 0) {\n const spaces = this._originalCode\n ? this._originalCode\n .slice(index - spacesCount, index)\n // https://tc39.es/ecma262/#sec-white-space\n .replace(/[^\\t\\v\\f\\uFEFF\\p{Space_Separator}]/gu, \" \")\n : \" \".repeat(spacesCount);\n this._append(spaces, false);\n }\n }\n\n /**\n * Get the current indent.\n */\n\n _getIndent(): number {\n return this._indentRepeat * this._indent;\n }\n\n printTerminatorless(node: t.Node) {\n /**\n * Set some state that will be modified if a newline has been inserted before any\n * non-space characters.\n *\n * This is to prevent breaking semantics for terminatorless separator nodes. eg:\n *\n * return foo;\n *\n * returns `foo`. But if we do:\n *\n * return\n * foo;\n *\n * `undefined` will be returned and not `foo` due to the terminator.\n */\n this._noLineTerminator = true;\n this.print(node);\n }\n\n print(\n node: t.Node | null,\n noLineTerminatorAfter?: boolean,\n // trailingCommentsLineOffset also used to check if called from printJoin\n // it will be ignored if `noLineTerminatorAfter||this._noLineTerminator`\n trailingCommentsLineOffset?: number,\n ) {\n if (!node) return;\n\n this._endsWithInnerRaw = false;\n\n const nodeType = node.type;\n const format = this.format;\n\n const oldConcise = format.concise;\n if (\n // @ts-expect-error document _compact AST properties\n node._compact\n ) {\n format.concise = true;\n }\n\n const printMethod =\n this[\n nodeType as Exclude<\n t.Node[\"type\"],\n | DeprecatedBabel7ASTTypes\n // renamed\n | t.DeprecatedAliases[\"type\"]\n >\n ];\n if (printMethod === undefined) {\n throw new ReferenceError(\n `unknown node of type ${JSON.stringify(\n nodeType,\n )} with constructor ${JSON.stringify(node.constructor.name)}`,\n );\n }\n\n const parent = this._currentNode;\n this._currentNode = node;\n\n if (this.tokenMap) {\n this._printSemicolonBeforeNextToken = this._printSemicolonBeforeNextNode;\n }\n\n const oldInAux = this._insideAux;\n this._insideAux = node.loc == null;\n this._maybeAddAuxComment(this._insideAux && !oldInAux);\n\n const parenthesized = node.extra?.parenthesized as boolean | undefined;\n let shouldPrintParens =\n (parenthesized && format.preserveFormat) ||\n (parenthesized &&\n format.retainFunctionParens &&\n nodeType === \"FunctionExpression\") ||\n needsParens(\n node,\n parent,\n this.tokenContext,\n this.inForStatementInit,\n format.preserveFormat ? this._boundGetRawIdentifier : undefined,\n );\n\n if (\n !shouldPrintParens &&\n parenthesized &&\n node.leadingComments?.length &&\n node.leadingComments[0].type === \"CommentBlock\"\n ) {\n const parentType = parent?.type;\n switch (parentType) {\n case \"ExpressionStatement\":\n case \"VariableDeclarator\":\n case \"AssignmentExpression\":\n case \"ReturnStatement\":\n break;\n case \"CallExpression\":\n case \"OptionalCallExpression\":\n case \"NewExpression\":\n if (parent.callee !== node) break;\n // falls through\n default:\n shouldPrintParens = true;\n }\n }\n\n let indentParenthesized = false;\n if (\n !shouldPrintParens &&\n this._noLineTerminator &&\n (node.leadingComments?.some(commentIsNewline) ||\n (this.format.retainLines &&\n node.loc &&\n node.loc.start.line > this._buf.getCurrentLine()))\n ) {\n shouldPrintParens = true;\n indentParenthesized = true;\n }\n\n let oldNoLineTerminatorAfterNode;\n let oldInForStatementInitWasTrue;\n if (!shouldPrintParens) {\n noLineTerminatorAfter ||=\n parent &&\n this._noLineTerminatorAfterNode === parent &&\n n.isLastChild(parent, node);\n if (noLineTerminatorAfter) {\n if (node.trailingComments?.some(commentIsNewline)) {\n if (isExpression(node)) shouldPrintParens = true;\n } else {\n oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n this._noLineTerminatorAfterNode = node;\n }\n }\n }\n\n if (shouldPrintParens) {\n this.token(\"(\");\n if (indentParenthesized) this.indent();\n this._endsWithInnerRaw = false;\n if (this.inForStatementInit) {\n oldInForStatementInitWasTrue = true;\n this.inForStatementInit = false;\n }\n oldNoLineTerminatorAfterNode = this._noLineTerminatorAfterNode;\n this._noLineTerminatorAfterNode = null;\n }\n\n this._lastCommentLine = 0;\n\n this._printLeadingComments(node, parent);\n\n const loc = nodeType === \"Program\" || nodeType === \"File\" ? null : node.loc;\n\n this.exactSource(\n loc,\n // @ts-expect-error Expected 1 arguments, but got 3.\n printMethod.bind(this, node, parent),\n );\n\n if (shouldPrintParens) {\n this._printTrailingComments(node, parent);\n if (indentParenthesized) {\n this.dedent();\n this.newline();\n }\n this.token(\")\");\n this._noLineTerminator = noLineTerminatorAfter;\n if (oldInForStatementInitWasTrue) this.inForStatementInit = true;\n } else if (noLineTerminatorAfter && !this._noLineTerminator) {\n this._noLineTerminator = true;\n this._printTrailingComments(node, parent);\n } else {\n this._printTrailingComments(node, parent, trailingCommentsLineOffset);\n }\n\n // end\n this._currentNode = parent;\n format.concise = oldConcise;\n this._insideAux = oldInAux;\n\n if (oldNoLineTerminatorAfterNode !== undefined) {\n this._noLineTerminatorAfterNode = oldNoLineTerminatorAfterNode;\n }\n\n this._endsWithInnerRaw = false;\n }\n\n _maybeAddAuxComment(enteredPositionlessNode?: boolean) {\n if (enteredPositionlessNode) this._printAuxBeforeComment();\n if (!this._insideAux) this._printAuxAfterComment();\n }\n\n _printAuxBeforeComment() {\n if (this._printAuxAfterOnNextUserNode) return;\n this._printAuxAfterOnNextUserNode = true;\n\n const comment = this.format.auxiliaryCommentBefore;\n if (comment) {\n this._printComment(\n {\n type: \"CommentBlock\",\n value: comment,\n },\n COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n }\n }\n\n _printAuxAfterComment() {\n if (!this._printAuxAfterOnNextUserNode) return;\n this._printAuxAfterOnNextUserNode = false;\n\n const comment = this.format.auxiliaryCommentAfter;\n if (comment) {\n this._printComment(\n {\n type: \"CommentBlock\",\n value: comment,\n },\n COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n }\n }\n\n getPossibleRaw(\n node:\n | t.StringLiteral\n | t.NumericLiteral\n | t.BigIntLiteral\n | t.DirectiveLiteral\n | t.JSXText,\n ): string | undefined {\n const extra = node.extra;\n if (\n extra?.raw != null &&\n extra.rawValue != null &&\n node.value === extra.rawValue\n ) {\n // @ts-expect-error: The extra.raw of these AST node types must be a string\n return extra.raw;\n }\n }\n\n printJoin(\n nodes: Array<t.Node> | undefined | null,\n statement?: boolean,\n indent?: boolean,\n separator?: PrintJoinOptions[\"separator\"],\n printTrailingSeparator?: boolean,\n addNewlines?: PrintJoinOptions[\"addNewlines\"],\n iterator?: PrintJoinOptions[\"iterator\"],\n trailingCommentsLineOffset?: number,\n ) {\n if (!nodes?.length) return;\n\n if (indent == null && this.format.retainLines) {\n const startLine = nodes[0].loc?.start.line;\n if (startLine != null && startLine !== this._buf.getCurrentLine()) {\n indent = true;\n }\n }\n\n if (indent) this.indent();\n\n const newlineOpts: AddNewlinesOptions = {\n addNewlines: addNewlines,\n nextNodeStartLine: 0,\n };\n\n const boundSeparator = separator?.bind(this);\n\n const len = nodes.length;\n for (let i = 0; i < len; i++) {\n const node = nodes[i];\n if (!node) continue;\n\n if (statement) this._printNewline(i === 0, newlineOpts);\n\n this.print(node, undefined, trailingCommentsLineOffset || 0);\n\n iterator?.(node, i);\n\n if (boundSeparator != null) {\n if (i < len - 1) boundSeparator(i, false);\n else if (printTrailingSeparator) boundSeparator(i, true);\n }\n\n if (statement) {\n if (!node.trailingComments?.length) {\n this._lastCommentLine = 0;\n }\n\n if (i + 1 === len) {\n this.newline(1);\n } else {\n const nextNode = nodes[i + 1];\n newlineOpts.nextNodeStartLine = nextNode.loc?.start.line || 0;\n\n this._printNewline(true, newlineOpts);\n }\n }\n }\n\n if (indent) this.dedent();\n }\n\n printAndIndentOnComments(node: t.Node) {\n const indent = node.leadingComments && node.leadingComments.length > 0;\n if (indent) this.indent();\n this.print(node);\n if (indent) this.dedent();\n }\n\n printBlock(parent: Extract<t.Node, { body: t.Statement }>) {\n const node = parent.body;\n\n if (node.type !== \"EmptyStatement\") {\n this.space();\n }\n\n this.print(node);\n }\n\n _printTrailingComments(node: t.Node, parent?: t.Node, lineOffset?: number) {\n const { innerComments, trailingComments } = node;\n // We print inner comments here, so that if for some reason they couldn't\n // be printed in earlier locations they are still printed *somewhere*,\n // even if at the end of the node.\n if (innerComments?.length) {\n this._printComments(\n COMMENT_TYPE.TRAILING,\n innerComments,\n node,\n parent,\n lineOffset,\n );\n }\n if (trailingComments?.length) {\n this._printComments(\n COMMENT_TYPE.TRAILING,\n trailingComments,\n node,\n parent,\n lineOffset,\n );\n }\n }\n\n _printLeadingComments(node: t.Node, parent: t.Node) {\n const comments = node.leadingComments;\n if (!comments?.length) return;\n this._printComments(COMMENT_TYPE.LEADING, comments, node, parent);\n }\n\n _maybePrintInnerComments(\n nextTokenStr: string,\n nextTokenOccurrenceCount?: number,\n ) {\n if (this._endsWithInnerRaw) {\n this.printInnerComments(\n this.tokenMap?.findMatching(\n this._currentNode,\n nextTokenStr,\n nextTokenOccurrenceCount,\n ),\n );\n }\n this._endsWithInnerRaw = true;\n this._indentInnerComments = true;\n }\n\n printInnerComments(nextToken?: Token) {\n const node = this._currentNode;\n const comments = node.innerComments;\n if (!comments?.length) return;\n\n const hasSpace = this.endsWith(charCodes.space);\n const indent = this._indentInnerComments;\n const printedCommentsCount = this._printedComments.size;\n if (indent) this.indent();\n this._printComments(\n COMMENT_TYPE.INNER,\n comments,\n node,\n undefined,\n undefined,\n nextToken,\n );\n if (hasSpace && printedCommentsCount !== this._printedComments.size) {\n this.space();\n }\n if (indent) this.dedent();\n }\n\n noIndentInnerCommentsHere() {\n this._indentInnerComments = false;\n }\n\n printSequence(\n nodes: t.Node[],\n indent?: boolean,\n trailingCommentsLineOffset?: number,\n addNewlines?: PrintSequenceOptions[\"addNewlines\"],\n ) {\n this.printJoin(\n nodes,\n true,\n indent ?? false,\n undefined,\n undefined,\n addNewlines,\n undefined,\n trailingCommentsLineOffset,\n );\n }\n\n printList(\n items: t.Node[],\n printTrailingSeparator?: boolean,\n statement?: boolean,\n indent?: boolean,\n separator?: PrintListOptions[\"separator\"],\n iterator?: PrintListOptions[\"iterator\"],\n ) {\n this.printJoin(\n items,\n statement,\n indent,\n separator ?? commaSeparator,\n printTrailingSeparator,\n undefined,\n iterator,\n );\n }\n\n shouldPrintTrailingComma(listEnd: string): boolean | null {\n if (!this.tokenMap) return null;\n\n const listEndIndex = this.tokenMap.findLastIndex(this._currentNode, token =>\n this.tokenMap.matchesOriginal(token, listEnd),\n );\n if (listEndIndex <= 0) return null;\n return this.tokenMap.matchesOriginal(this._tokens[listEndIndex - 1], \",\");\n }\n\n _printNewline(newLine: boolean, opts: AddNewlinesOptions) {\n const format = this.format;\n\n // Fast path since 'this.newline' does nothing when not tracking lines.\n if (format.retainLines || format.compact) return;\n\n // Fast path for concise since 'this.newline' just inserts a space when\n // concise formatting is in use.\n if (format.concise) {\n this.space();\n return;\n }\n\n if (!newLine) {\n return;\n }\n\n const startLine = opts.nextNodeStartLine;\n const lastCommentLine = this._lastCommentLine;\n if (startLine > 0 && lastCommentLine > 0) {\n const offset = startLine - lastCommentLine;\n if (offset >= 0) {\n this.newline(offset || 1);\n return;\n }\n }\n\n // don't add newlines at the beginning of the file\n if (this._buf.hasContent()) {\n // Here is the logic of the original line wrapping according to the node layout, we are not using it now.\n // We currently add at most one newline to each node in the list, ignoring `opts.addNewlines`.\n\n // let lines = 0;\n // if (!leading) lines++; // always include at least a single line after\n // if (opts.addNewlines) lines += opts.addNewlines(leading, node) || 0;\n\n // const needs = leading ? needsWhitespaceBefore : needsWhitespaceAfter;\n // if (needs(node, parent)) lines++;\n\n // this.newline(Math.min(2, lines));\n\n this.newline(1);\n }\n }\n\n // Returns `PRINT_COMMENT_HINT.DEFER` if the comment cannot be printed in this position due to\n // line terminators, signaling that the print comments loop can stop and\n // resume printing comments at the next possible position. This happens when\n // printing inner comments, since if we have an inner comment with a multiline\n // there is at least one inner position where line terminators are allowed.\n _shouldPrintComment(\n comment: t.Comment,\n nextToken?: Token,\n ): PRINT_COMMENT_HINT {\n // Some plugins (such as flow-strip-types) use this to mark comments as removed using the AST-root 'comments' property,\n // where they can't manually mutate the AST node comment lists.\n if (comment.ignore) return PRINT_COMMENT_HINT.SKIP;\n\n if (this._printedComments.has(comment)) return PRINT_COMMENT_HINT.SKIP;\n\n if (\n this._noLineTerminator &&\n HAS_NEWLINE_OR_BlOCK_COMMENT_END.test(comment.value)\n ) {\n return PRINT_COMMENT_HINT.DEFER;\n }\n\n if (nextToken && this.tokenMap) {\n const commentTok = this.tokenMap.find(\n this._currentNode,\n token => token.value === comment.value,\n );\n if (commentTok && commentTok.start > nextToken.start) {\n return PRINT_COMMENT_HINT.DEFER;\n }\n }\n\n this._printedComments.add(comment);\n\n if (!this.format.shouldPrintComment(comment.value)) {\n return PRINT_COMMENT_HINT.SKIP;\n }\n\n return PRINT_COMMENT_HINT.ALLOW;\n }\n\n _printComment(comment: t.Comment, skipNewLines: COMMENT_SKIP_NEWLINE) {\n const noLineTerminator = this._noLineTerminator;\n const isBlockComment = comment.type === \"CommentBlock\";\n\n // Add a newline before and after a block comment, unless explicitly\n // disallowed\n const printNewLines =\n isBlockComment &&\n skipNewLines !== COMMENT_SKIP_NEWLINE.ALL &&\n !this._noLineTerminator;\n\n if (\n printNewLines &&\n this._buf.hasContent() &&\n skipNewLines !== COMMENT_SKIP_NEWLINE.LEADING\n ) {\n this.newline(1);\n }\n\n const lastCharCode = this.getLastChar();\n if (\n lastCharCode !== charCodes.leftSquareBracket &&\n lastCharCode !== charCodes.leftCurlyBrace &&\n lastCharCode !== charCodes.leftParenthesis\n ) {\n this.space();\n }\n\n let val;\n if (isBlockComment) {\n val = `/*${comment.value}*/`;\n if (this.format.indent.adjustMultilineComment) {\n const offset = comment.loc?.start.column;\n if (offset) {\n const newlineRegex = new RegExp(\"\\\\n\\\\s{1,\" + offset + \"}\", \"g\");\n val = val.replace(newlineRegex, \"\\n\");\n }\n if (this.format.concise) {\n val = val.replace(/\\n(?!$)/g, `\\n`);\n } else {\n let indentSize = this.format.retainLines\n ? 0\n : this._buf.getCurrentColumn();\n\n if (this._shouldIndent(charCodes.slash) || this.format.retainLines) {\n indentSize += this._getIndent();\n }\n\n val = val.replace(/\\n(?!$)/g, `\\n${\" \".repeat(indentSize)}`);\n }\n }\n } else if (!noLineTerminator) {\n val = `//${comment.value}`;\n } else {\n // It was a single-line comment, so it's guaranteed to not\n // contain newlines and it can be safely printed as a block\n // comment.\n val = `/*${comment.value}*/`;\n }\n\n // Avoid converting a / operator into a line comment by appending /* to it\n if (this._endsWithDiv) this._space();\n\n if (this.tokenMap) {\n const { _printSemicolonBeforeNextToken, _printSemicolonBeforeNextNode } =\n this;\n this._printSemicolonBeforeNextToken = -1;\n this._printSemicolonBeforeNextNode = -1;\n this.source(\"start\", comment.loc);\n this._append(val, isBlockComment);\n this._printSemicolonBeforeNextNode = _printSemicolonBeforeNextNode;\n this._printSemicolonBeforeNextToken = _printSemicolonBeforeNextToken;\n } else {\n this.source(\"start\", comment.loc);\n this._append(val, isBlockComment);\n }\n\n if (!isBlockComment && !noLineTerminator) {\n this.newline(1, true);\n }\n\n if (printNewLines && skipNewLines !== COMMENT_SKIP_NEWLINE.TRAILING) {\n this.newline(1);\n }\n }\n\n _printComments(\n type: COMMENT_TYPE,\n comments: readonly t.Comment[],\n node: t.Node,\n parent?: t.Node,\n lineOffset: number = 0,\n nextToken?: Token,\n ) {\n const nodeLoc = node.loc;\n const len = comments.length;\n let hasLoc = !!nodeLoc;\n const nodeStartLine = hasLoc ? nodeLoc.start.line : 0;\n const nodeEndLine = hasLoc ? nodeLoc.end.line : 0;\n let lastLine = 0;\n let leadingCommentNewline = 0;\n\n const maybeNewline = this._noLineTerminator\n ? function () {}\n : this.newline.bind(this);\n\n for (let i = 0; i < len; i++) {\n const comment = comments[i];\n\n const shouldPrint = this._shouldPrintComment(comment, nextToken);\n if (shouldPrint === PRINT_COMMENT_HINT.DEFER) {\n hasLoc = false;\n break;\n }\n if (hasLoc && comment.loc && shouldPrint === PRINT_COMMENT_HINT.ALLOW) {\n const commentStartLine = comment.loc.start.line;\n const commentEndLine = comment.loc.end.line;\n if (type === COMMENT_TYPE.LEADING) {\n let offset = 0;\n if (i === 0) {\n // Because currently we cannot handle blank lines before leading comments,\n // we always wrap before and after multi-line comments.\n if (\n this._buf.hasContent() &&\n (comment.type === \"CommentLine\" ||\n commentStartLine !== commentEndLine)\n ) {\n offset = leadingCommentNewline = 1;\n }\n } else {\n offset = commentStartLine - lastLine;\n }\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n\n if (i + 1 === len) {\n maybeNewline(\n Math.max(nodeStartLine - lastLine, leadingCommentNewline),\n );\n lastLine = nodeStartLine;\n }\n } else if (type === COMMENT_TYPE.INNER) {\n const offset =\n commentStartLine - (i === 0 ? nodeStartLine : lastLine);\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n\n if (i + 1 === len) {\n maybeNewline(Math.min(1, nodeEndLine - lastLine)); // TODO: Improve here when inner comments processing is stronger\n lastLine = nodeEndLine;\n }\n } else {\n const offset =\n commentStartLine - (i === 0 ? nodeEndLine - lineOffset : lastLine);\n lastLine = commentEndLine;\n\n maybeNewline(offset);\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n }\n } else {\n hasLoc = false;\n if (shouldPrint !== PRINT_COMMENT_HINT.ALLOW) {\n continue;\n }\n\n if (len === 1) {\n const singleLine = comment.loc\n ? comment.loc.start.line === comment.loc.end.line\n : !HAS_NEWLINE.test(comment.value);\n\n const shouldSkipNewline =\n singleLine &&\n !isStatement(node) &&\n !isClassBody(parent) &&\n !isTSInterfaceBody(parent) &&\n !isTSEnumMember(node);\n\n if (type === COMMENT_TYPE.LEADING) {\n this._printComment(\n comment,\n (shouldSkipNewline && node.type !== \"ObjectExpression\") ||\n (singleLine && isFunction(parent, { body: node }))\n ? COMMENT_SKIP_NEWLINE.ALL\n : COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n } else if (shouldSkipNewline && type === COMMENT_TYPE.TRAILING) {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.ALL);\n } else {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.DEFAULT);\n }\n } else if (\n type === COMMENT_TYPE.INNER &&\n !(node.type === \"ObjectExpression\" && node.properties.length > 1) &&\n node.type !== \"ClassBody\" &&\n node.type !== \"TSInterfaceBody\"\n ) {\n // class X {\n // /*:: a: number*/\n // /*:: b: ?string*/\n // }\n\n this._printComment(\n comment,\n i === 0\n ? COMMENT_SKIP_NEWLINE.LEADING\n : i === len - 1\n ? COMMENT_SKIP_NEWLINE.TRAILING\n : COMMENT_SKIP_NEWLINE.DEFAULT,\n );\n } else {\n this._printComment(comment, COMMENT_SKIP_NEWLINE.DEFAULT);\n }\n }\n }\n\n if (type === COMMENT_TYPE.TRAILING && hasLoc && lastLine) {\n this._lastCommentLine = lastLine;\n }\n }\n}\n\n// Expose the node type functions and helpers on the prototype for easy usage.\nObject.assign(Printer.prototype, generatorFunctions);\n\nif (!process.env.BABEL_8_BREAKING) {\n addDeprecatedGenerators(Printer);\n}\n\ntype GeneratorFunctions = typeof generatorFunctions;\n// eslint-disable-next-line @typescript-eslint/no-empty-object-type\ninterface Printer extends GeneratorFunctions {}\nexport default Printer;\n\nfunction commaSeparator(this: Printer, occurrenceCount: number, last: boolean) {\n this.token(\",\", false, occurrenceCount);\n if (!last) this.space();\n}\n"],"mappings":";;;;;;AAAA,IAAAA,OAAA,GAAAC,OAAA;AAEA,IAAAC,CAAA,GAAAD,OAAA;AAEA,IAAAE,EAAA,GAAAF,OAAA;AAUA,IAAAG,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L,IAAI,EAAE,IAAI,CAAClM,KAAK,CAAC,CAAC;AACzB","ignoreList":[]} -
imaps-frontend/node_modules/@babel/generator/package.json
r0c6b92a r79a0317 1 1 { 2 2 "name": "@babel/generator", 3 "version": "7.26. 2",3 "version": "7.26.5", 4 4 "description": "Turns an AST into code.", 5 5 "author": "The Babel Team (https://babel.dev/team)", … … 20 20 ], 21 21 "dependencies": { 22 "@babel/parser": "^7.26. 2",23 "@babel/types": "^7.26. 0",22 "@babel/parser": "^7.26.5", 23 "@babel/types": "^7.26.5", 24 24 "@jridgewell/gen-mapping": "^0.3.5", 25 25 "@jridgewell/trace-mapping": "^0.3.25", … … 29 29 "@babel/core": "^7.26.0", 30 30 "@babel/helper-fixtures": "^7.26.0", 31 "@babel/plugin-transform-typescript": "^7.2 5.9",31 "@babel/plugin-transform-typescript": "^7.26.5", 32 32 "@jridgewell/sourcemap-codec": "^1.4.15", 33 33 "@types/jsesc": "^2.5.0",
Note:
See TracChangeset
for help on using the changeset viewer.