@idlizer/arktscgen 2.1.9-arktscgen-9 → 2.1.10-arktscgen-3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/libarkts-copy/generator/options.json5 +199 -4
- package/build/libarkts-copy/native/meson.build +1 -0
- package/build/libarkts-copy/native/mingw.cross +13 -0
- package/build/libarkts-copy/native/src/bridges.cc +66 -229
- package/build/libarkts-copy/native/src/common.cc +37 -8
- package/build/libarkts-copy/native/src/generated/bridges.cc +2047 -766
- package/build/libarkts-copy/native/src/memoryTracker.cc +178 -0
- package/build/libarkts-copy/native/src/memoryTracker.h +52 -0
- package/build/libarkts-copy/package.json +11 -14
- package/build/libarkts-copy/src/Es2pandaNativeModule.ts +41 -52
- package/build/libarkts-copy/src/arkts-api/ImportStorage.ts +1 -1
- package/build/libarkts-copy/src/arkts-api/class-by-peer.ts +7 -6
- package/build/libarkts-copy/src/arkts-api/factory/nodeFactory.ts +5 -2
- package/build/libarkts-copy/src/arkts-api/index.ts +2 -1
- package/build/libarkts-copy/src/arkts-api/node-cache.ts +9 -9
- package/build/libarkts-copy/src/arkts-api/node-utilities/ArkTsConfig.ts +7 -6
- package/build/libarkts-copy/src/arkts-api/node-utilities/NumberLiteral.ts +3 -1
- package/build/libarkts-copy/src/arkts-api/node-utilities/ObjectExpression.ts +25 -6
- package/build/libarkts-copy/src/{wrapper-compat/arkts-api/peers/ImportPathManager.ts → arkts-api/node-utilities/OpaqueTypeNode.ts} +8 -17
- package/build/libarkts-copy/src/arkts-api/node-utilities/Program.ts +11 -10
- package/build/libarkts-copy/src/arkts-api/node-utilities/ScriptFunction.ts +1 -1
- package/build/libarkts-copy/src/arkts-api/peers/AstNode.ts +12 -7
- package/build/libarkts-copy/src/arkts-api/peers/Config.ts +6 -0
- package/build/libarkts-copy/src/arkts-api/peers/Context.ts +3 -15
- package/build/libarkts-copy/src/{wrapper-compat/arkts-api/peers/AstNode.ts → arkts-api/peers/DiagnosticKind.ts} +6 -8
- package/build/libarkts-copy/src/arkts-api/static/global.ts +28 -1
- package/build/libarkts-copy/src/arkts-api/utilities/extensions.ts +64 -7
- package/build/libarkts-copy/src/{wrapper-compat/arkts-api → arkts-api}/utilities/performance.ts +122 -3
- package/build/libarkts-copy/src/arkts-api/utilities/private.ts +8 -22
- package/build/libarkts-copy/src/arkts-api/utilities/public.ts +95 -93
- package/build/libarkts-copy/src/arkts-api/visitor.ts +971 -364
- package/build/libarkts-copy/src/generated/Es2pandaEnums.ts +6 -0
- package/build/libarkts-copy/src/generated/Es2pandaNativeModule.ts +686 -185
- package/build/libarkts-copy/src/generated/factory.ts +2 -3
- package/build/libarkts-copy/src/generated/index.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/AnnotatedAstNode.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/AnnotatedExpression.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/AnnotatedStatement.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/AnnotationDeclaration.ts +17 -20
- package/build/libarkts-copy/src/generated/peers/AnnotationUsage.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/ArkTsConfig.ts +4 -1
- package/build/libarkts-copy/src/generated/peers/ArrayExpression.ts +6 -12
- package/build/libarkts-copy/src/generated/peers/ArrowFunctionExpression.ts +18 -21
- package/build/libarkts-copy/src/generated/peers/AssertStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/AssignmentExpression.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/AstDumper.ts +3 -1
- package/build/libarkts-copy/src/generated/peers/AstVerifier.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/AstVisitor.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/AwaitExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BigIntLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BinaryExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BindingProps.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/BlockExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BlockStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BooleanLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/BreakStatement.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/CallExpression.ts +11 -8
- package/build/libarkts-copy/src/generated/peers/CatchClause.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ChainExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/CharLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ClassDeclaration.ts +6 -30
- package/build/libarkts-copy/src/generated/peers/ClassDefinition.ts +35 -28
- package/build/libarkts-copy/src/generated/peers/ClassElement.ts +5 -32
- package/build/libarkts-copy/src/generated/peers/ClassExpression.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ClassProperty.ts +25 -20
- package/build/libarkts-copy/src/generated/peers/ClassStaticBlock.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/CodeGen.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ConditionalExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ContinueStatement.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/DebuggerStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/Declaration.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/Decorator.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/DiagnosticInfo.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/DirectEvalExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/DoWhileStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/DynamicImportData.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ETSClassLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSFunctionType.ts +14 -9
- package/build/libarkts-copy/src/generated/peers/ETSImportDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSIntrinsicNode.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/ETSKeyofType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSModule.ts +17 -20
- package/build/libarkts-copy/src/generated/peers/ETSNewArrayInstanceExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSNewClassInstanceExpression.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ETSNewMultiDimArrayInstanceExpression.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ETSNullType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSPackageDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSParameterExpression.ts +20 -23
- package/build/libarkts-copy/src/generated/peers/ETSPrimitiveType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSReExportDeclaration.ts +4 -6
- package/build/libarkts-copy/src/generated/peers/ETSStringLiteralType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSStructDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSTuple.ts +9 -11
- package/build/libarkts-copy/src/generated/peers/ETSTypeReference.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/ETSTypeReferencePart.ts +9 -11
- package/build/libarkts-copy/src/generated/peers/ETSUndefinedType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSUnionType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ETSWildcardType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/EmptyStatement.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ErrorLogger.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ExportAllDeclaration.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/ExportDefaultDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ExportNamedDeclaration.ts +11 -13
- package/build/libarkts-copy/src/generated/peers/ExportSpecifier.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/Expression.ts +7 -3
- package/build/libarkts-copy/src/generated/peers/ExpressionStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ForInStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ForOfStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ForUpdateStatement.ts +4 -6
- package/build/libarkts-copy/src/generated/peers/FunctionDeclaration.ts +16 -23
- package/build/libarkts-copy/src/generated/peers/FunctionExpression.ts +8 -10
- package/build/libarkts-copy/src/generated/peers/FunctionSignature.ts +5 -2
- package/build/libarkts-copy/src/generated/peers/IRNode.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/Identifier.ts +7 -18
- package/build/libarkts-copy/src/generated/peers/IfStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ImportDeclaration.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ImportDefaultSpecifier.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ImportExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ImportNamespaceSpecifier.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ImportSource.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ImportSpecifier.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/IndexInfo.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/LabelPair.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/LabelledStatement.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/Literal.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/LoopStatement.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/MaybeOptionalExpression.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/MemberExpression.ts +5 -11
- package/build/libarkts-copy/src/generated/peers/MetaProperty.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/MethodDefinition.ts +10 -12
- package/build/libarkts-copy/src/generated/peers/NamedType.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/NewExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/NullLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/NumberLiteral.ts +10 -10
- package/build/libarkts-copy/src/generated/peers/ObjectDescriptor.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ObjectExpression.ts +5 -11
- package/build/libarkts-copy/src/generated/peers/OmittedExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/OpaqueTypeNode.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/OverloadDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/PrefixAssertionExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/Program.ts +9 -2
- package/build/libarkts-copy/src/generated/peers/Property.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/RegExpLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ReturnStatement.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ScopeFindResult.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ScriptFunction.ts +27 -23
- package/build/libarkts-copy/src/generated/peers/ScriptFunctionData.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/SequenceExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/SignatureInfo.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/SourcePosition.ts +8 -1
- package/build/libarkts-copy/src/generated/peers/SourceRange.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/SpreadElement.ts +5 -11
- package/build/libarkts-copy/src/generated/peers/SrcDumper.ts +3 -1
- package/build/libarkts-copy/src/generated/peers/Statement.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/StringLiteral.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/SuggestionInfo.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/SuperExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/SwitchCaseStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/SwitchStatement.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSAnyKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSArrayType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSAsExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSBigintKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSBooleanKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSClassImplements.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/TSConditionalType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSConstructorType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSEnumDeclaration.ts +8 -32
- package/build/libarkts-copy/src/generated/peers/TSEnumMember.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSExternalModuleReference.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSFunctionType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSImportEqualsDeclaration.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSImportType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSIndexSignature.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSIndexedAccessType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSInferType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSInterfaceBody.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSInterfaceDeclaration.ts +19 -44
- package/build/libarkts-copy/src/generated/peers/TSInterfaceHeritage.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSIntersectionType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSLiteralType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSMappedType.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSMethodSignature.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSModuleBlock.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSModuleDeclaration.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSNamedTupleMember.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSNeverKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSNonNullExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSNullKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSNumberKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSObjectKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSParameterProperty.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSParenthesizedType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSPropertySignature.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSQualifiedName.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/TSSignatureDeclaration.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSStringKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSThisType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTupleType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeAliasDeclaration.ts +32 -47
- package/build/libarkts-copy/src/generated/peers/TSTypeAssertion.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeOperator.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeParameter.ts +17 -20
- package/build/libarkts-copy/src/generated/peers/TSTypeParameterDeclaration.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TSTypeParameterInstantiation.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypePredicate.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeQuery.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeReference.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/TSUndefinedKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSUnionType.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSUnknownKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TSVoidKeyword.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TaggedTemplateExpression.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/TemplateElement.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/TemplateLiteral.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/ThisExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/ThrowStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/TryStatement.ts +7 -9
- package/build/libarkts-copy/src/generated/peers/TypeNode.ts +13 -14
- package/build/libarkts-copy/src/generated/peers/TypedAstNode.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/TypedStatement.ts +3 -3
- package/build/libarkts-copy/src/generated/peers/TypeofExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/UnaryExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/UndefinedLiteral.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/UpdateExpression.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/VReg.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/ValidationInfo.ts +3 -1
- package/build/libarkts-copy/src/generated/peers/VariableDeclaration.ts +16 -26
- package/build/libarkts-copy/src/generated/peers/VariableDeclarator.ts +6 -8
- package/build/libarkts-copy/src/generated/peers/VerificationContext.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/VerifierMessage.ts +0 -1
- package/build/libarkts-copy/src/generated/peers/WhileStatement.ts +5 -7
- package/build/libarkts-copy/src/generated/peers/YieldExpression.ts +5 -7
- package/build/libarkts-copy/src/index.ts +4 -1
- package/build/libarkts-copy/src/plugin-utils.ts +8 -11
- package/build/libarkts-copy/src/reexport-for-generated.ts +1 -12
- package/build/libarkts-copy/src/tracer.ts +172 -0
- package/build/libarkts-copy/src/utils.ts +3 -0
- package/lib/index.js +1403 -544
- package/package.json +4 -3
- package/templates/factory.ts +0 -1
- package/templates/peer.ts +0 -1
- package/build/libarkts-copy/src/arkts-api/ChainExpressionFilter.ts +0 -79
- package/build/libarkts-copy/src/arkts-api/peers/SourcePosition.ts +0 -38
- package/build/libarkts-copy/src/generated/peers/FunctionDecl.ts +0 -45
- package/build/libarkts-copy/src/generated/peers/InterfaceDecl.ts +0 -45
- package/build/libarkts-copy/src/wrapper-compat/README.md +0 -20
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/class-by-peer.ts +0 -46
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/factory/nodeFactory.ts +0 -454
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/factory/nodeTests.ts +0 -99
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/index.ts +0 -88
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ArrayExpression.ts +0 -38
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ArrowFunctionExpression.ts +0 -35
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/AssignmentExpression.ts +0 -38
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/BlockStatement.ts +0 -27
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/CallExpression.ts +0 -45
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ClassDeclaration.ts +0 -27
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ClassDefinition.ts +0 -73
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ClassProperty.ts +0 -51
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ETSFunctionType.ts +0 -42
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ETSImportDeclaration.ts +0 -39
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ETSParameterExpression.ts +0 -43
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ExpressionStatement.ts +0 -28
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/FunctionDeclaration.ts +0 -37
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/FunctionExpression.ts +0 -28
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/IfStatement.ts +0 -37
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/MemberExpression.ts +0 -42
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/MethodDefinition.ts +0 -46
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/NumberLiteral.ts +0 -30
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ObjectExpression.ts +0 -37
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/Property.ts +0 -27
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/ScriptFunction.ts +0 -46
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/StructDeclaration.ts +0 -28
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/TSInterfaceDeclaration.ts +0 -47
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/TSTypeAliasDeclaration.ts +0 -40
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/TSTypeParameter.ts +0 -36
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/TryStatement.ts +0 -41
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/VariableDeclaration.ts +0 -42
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/node-utilities/VariableDeclarator.ts +0 -39
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/Diagnostic.ts +0 -38
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/DiagnosticInfo.ts +0 -34
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/DiagnosticKind.ts +0 -33
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/Program.ts +0 -105
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/SourcePosition.ts +0 -38
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/SourceRange.ts +0 -38
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/peers/SuggestionInfo.ts +0 -34
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/static/global.ts +0 -16
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/to-be-generated/MemberExpression.ts +0 -108
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/types.ts +0 -889
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/utilities/nativePtrDecoder.ts +0 -69
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/utilities/private.ts +0 -198
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/utilities/public.ts +0 -327
- package/build/libarkts-copy/src/wrapper-compat/arkts-api/visitor.ts +0 -421
- package/build/libarkts-copy/src/wrapper-compat/index.ts +0 -20
- package/templates/node-map.ts +0 -35
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,25 +37,24 @@ import { Statement } from "./Statement"
|
|
|
38
37
|
import { StringLiteral } from "./StringLiteral"
|
|
39
38
|
|
|
40
39
|
export class ExportAllDeclaration extends Statement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createExportAllDeclaration(source?: StringLiteral, exported?: Identifier): ExportAllDeclaration {
|
|
46
|
-
const result: ExportAllDeclaration = new ExportAllDeclaration(global.generatedEs2panda._CreateExportAllDeclaration(global.context, passNode(source), passNode(exported)))
|
|
44
|
+
const result: ExportAllDeclaration = new ExportAllDeclaration(global.generatedEs2panda._CreateExportAllDeclaration(global.context, passNode(source), passNode(exported)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateExportAllDeclaration(original?: ExportAllDeclaration, source?: StringLiteral, exported?: Identifier): ExportAllDeclaration {
|
|
51
|
-
const result: ExportAllDeclaration = new ExportAllDeclaration(global.generatedEs2panda._UpdateExportAllDeclaration(global.context, passNode(original), passNode(source), passNode(exported)))
|
|
49
|
+
const result: ExportAllDeclaration = new ExportAllDeclaration(global.generatedEs2panda._UpdateExportAllDeclaration(global.context, passNode(original), passNode(source), passNode(exported)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
55
53
|
get source(): StringLiteral | undefined {
|
|
56
|
-
return unpackNode(global.generatedEs2panda._ExportAllDeclarationSourceConst(global.context, this.peer))
|
|
54
|
+
return unpackNode(global.generatedEs2panda._ExportAllDeclarationSourceConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_STRING_LITERAL)
|
|
57
55
|
}
|
|
58
56
|
get exported(): Identifier | undefined {
|
|
59
|
-
return unpackNode(global.generatedEs2panda._ExportAllDeclarationExportedConst(global.context, this.peer))
|
|
57
|
+
return unpackNode(global.generatedEs2panda._ExportAllDeclarationExportedConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_IDENTIFIER)
|
|
60
58
|
}
|
|
61
59
|
protected readonly brandExportAllDeclaration: undefined
|
|
62
60
|
}
|
|
@@ -64,5 +62,5 @@ export function isExportAllDeclaration(node: object | undefined): node is Export
|
|
|
64
62
|
return node instanceof ExportAllDeclaration
|
|
65
63
|
}
|
|
66
64
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION)) {
|
|
67
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION, (peer: KNativePointer) => new ExportAllDeclaration(peer))
|
|
65
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION, (peer: KNativePointer) => new ExportAllDeclaration(peer, Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_ALL_DECLARATION))
|
|
68
66
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -36,17 +35,16 @@ import { Es2pandaAstNodeType } from "./../Es2pandaEnums"
|
|
|
36
35
|
import { Statement } from "./Statement"
|
|
37
36
|
|
|
38
37
|
export class ExportDefaultDeclaration extends Statement {
|
|
39
|
-
constructor(pointer: KNativePointer) {
|
|
40
|
-
|
|
41
|
-
super(pointer)
|
|
38
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
39
|
+
super(pointer, astNodeType)
|
|
42
40
|
}
|
|
43
41
|
static createExportDefaultDeclaration(decl: AstNode | undefined, exportEquals: boolean): ExportDefaultDeclaration {
|
|
44
|
-
const result: ExportDefaultDeclaration = new ExportDefaultDeclaration(global.generatedEs2panda._CreateExportDefaultDeclaration(global.context, passNode(decl), exportEquals))
|
|
42
|
+
const result: ExportDefaultDeclaration = new ExportDefaultDeclaration(global.generatedEs2panda._CreateExportDefaultDeclaration(global.context, passNode(decl), exportEquals), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION)
|
|
45
43
|
result.setChildrenParentPtr()
|
|
46
44
|
return result
|
|
47
45
|
}
|
|
48
46
|
static updateExportDefaultDeclaration(original: ExportDefaultDeclaration | undefined, decl: AstNode | undefined, exportEquals: boolean): ExportDefaultDeclaration {
|
|
49
|
-
const result: ExportDefaultDeclaration = new ExportDefaultDeclaration(global.generatedEs2panda._UpdateExportDefaultDeclaration(global.context, passNode(original), passNode(decl), exportEquals))
|
|
47
|
+
const result: ExportDefaultDeclaration = new ExportDefaultDeclaration(global.generatedEs2panda._UpdateExportDefaultDeclaration(global.context, passNode(original), passNode(decl), exportEquals), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION)
|
|
50
48
|
result.setChildrenParentPtr()
|
|
51
49
|
return result
|
|
52
50
|
}
|
|
@@ -62,5 +60,5 @@ export function isExportDefaultDeclaration(node: object | undefined): node is Ex
|
|
|
62
60
|
return node instanceof ExportDefaultDeclaration
|
|
63
61
|
}
|
|
64
62
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION)) {
|
|
65
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION, (peer: KNativePointer) => new ExportDefaultDeclaration(peer))
|
|
63
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION, (peer: KNativePointer) => new ExportDefaultDeclaration(peer, Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_DEFAULT_DECLARATION))
|
|
66
64
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,37 +37,36 @@ import { Statement } from "./Statement"
|
|
|
38
37
|
import { StringLiteral } from "./StringLiteral"
|
|
39
38
|
|
|
40
39
|
export class ExportNamedDeclaration extends Statement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createExportNamedDeclaration(source: StringLiteral | undefined, specifiers: readonly ExportSpecifier[]): ExportNamedDeclaration {
|
|
46
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration(global.context, passNode(source), passNodeArray(specifiers), specifiers.length))
|
|
44
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration(global.context, passNode(source), passNodeArray(specifiers), specifiers.length), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateExportNamedDeclaration(original: ExportNamedDeclaration | undefined, source: StringLiteral | undefined, specifiers: readonly ExportSpecifier[]): ExportNamedDeclaration {
|
|
51
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration(global.context, passNode(original), passNode(source), passNodeArray(specifiers), specifiers.length))
|
|
49
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration(global.context, passNode(original), passNode(source), passNodeArray(specifiers), specifiers.length), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
55
53
|
static create1ExportNamedDeclaration(decl: AstNode | undefined, specifiers: readonly ExportSpecifier[]): ExportNamedDeclaration {
|
|
56
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration1(global.context, passNode(decl), passNodeArray(specifiers), specifiers.length))
|
|
54
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration1(global.context, passNode(decl), passNodeArray(specifiers), specifiers.length), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
57
55
|
result.setChildrenParentPtr()
|
|
58
56
|
return result
|
|
59
57
|
}
|
|
60
58
|
static update1ExportNamedDeclaration(original: ExportNamedDeclaration | undefined, decl: AstNode | undefined, specifiers: readonly ExportSpecifier[]): ExportNamedDeclaration {
|
|
61
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration1(global.context, passNode(original), passNode(decl), passNodeArray(specifiers), specifiers.length))
|
|
59
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration1(global.context, passNode(original), passNode(decl), passNodeArray(specifiers), specifiers.length), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
62
60
|
result.setChildrenParentPtr()
|
|
63
61
|
return result
|
|
64
62
|
}
|
|
65
63
|
static create2ExportNamedDeclaration(decl?: AstNode): ExportNamedDeclaration {
|
|
66
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration2(global.context, passNode(decl)))
|
|
64
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._CreateExportNamedDeclaration2(global.context, passNode(decl)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
67
65
|
result.setChildrenParentPtr()
|
|
68
66
|
return result
|
|
69
67
|
}
|
|
70
68
|
static update2ExportNamedDeclaration(original?: ExportNamedDeclaration, decl?: AstNode): ExportNamedDeclaration {
|
|
71
|
-
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration2(global.context, passNode(original), passNode(decl)))
|
|
69
|
+
const result: ExportNamedDeclaration = new ExportNamedDeclaration(global.generatedEs2panda._UpdateExportNamedDeclaration2(global.context, passNode(original), passNode(decl)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)
|
|
72
70
|
result.setChildrenParentPtr()
|
|
73
71
|
return result
|
|
74
72
|
}
|
|
@@ -76,10 +74,10 @@ export class ExportNamedDeclaration extends Statement {
|
|
|
76
74
|
return unpackNode(global.generatedEs2panda._ExportNamedDeclarationDeclConst(global.context, this.peer))
|
|
77
75
|
}
|
|
78
76
|
get source(): StringLiteral | undefined {
|
|
79
|
-
return unpackNode(global.generatedEs2panda._ExportNamedDeclarationSourceConst(global.context, this.peer))
|
|
77
|
+
return unpackNode(global.generatedEs2panda._ExportNamedDeclarationSourceConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_STRING_LITERAL)
|
|
80
78
|
}
|
|
81
79
|
get specifiers(): readonly ExportSpecifier[] {
|
|
82
|
-
return unpackNodeArray(global.generatedEs2panda._ExportNamedDeclarationSpecifiersConst(global.context, this.peer))
|
|
80
|
+
return unpackNodeArray(global.generatedEs2panda._ExportNamedDeclarationSpecifiersConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER)
|
|
83
81
|
}
|
|
84
82
|
/** @deprecated */
|
|
85
83
|
replaceSpecifiers(specifiers: readonly ExportSpecifier[]): this {
|
|
@@ -92,5 +90,5 @@ export function isExportNamedDeclaration(node: object | undefined): node is Expo
|
|
|
92
90
|
return node instanceof ExportNamedDeclaration
|
|
93
91
|
}
|
|
94
92
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION)) {
|
|
95
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION, (peer: KNativePointer) => new ExportNamedDeclaration(peer))
|
|
93
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION, (peer: KNativePointer) => new ExportNamedDeclaration(peer, Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_NAMED_DECLARATION))
|
|
96
94
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,25 +37,24 @@ import { Identifier } from "./Identifier"
|
|
|
38
37
|
import { Statement } from "./Statement"
|
|
39
38
|
|
|
40
39
|
export class ExportSpecifier extends Statement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createExportSpecifier(local?: Identifier, exported?: Identifier): ExportSpecifier {
|
|
46
|
-
const result: ExportSpecifier = new ExportSpecifier(global.generatedEs2panda._CreateExportSpecifier(global.context, passNode(local), passNode(exported)))
|
|
44
|
+
const result: ExportSpecifier = new ExportSpecifier(global.generatedEs2panda._CreateExportSpecifier(global.context, passNode(local), passNode(exported)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateExportSpecifier(original?: ExportSpecifier, local?: Identifier, exported?: Identifier): ExportSpecifier {
|
|
51
|
-
const result: ExportSpecifier = new ExportSpecifier(global.generatedEs2panda._UpdateExportSpecifier(global.context, passNode(original), passNode(local), passNode(exported)))
|
|
49
|
+
const result: ExportSpecifier = new ExportSpecifier(global.generatedEs2panda._UpdateExportSpecifier(global.context, passNode(original), passNode(local), passNode(exported)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
55
53
|
get local(): Identifier | undefined {
|
|
56
|
-
return unpackNode(global.generatedEs2panda._ExportSpecifierLocalConst(global.context, this.peer))
|
|
54
|
+
return unpackNode(global.generatedEs2panda._ExportSpecifierLocalConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_IDENTIFIER)
|
|
57
55
|
}
|
|
58
56
|
get exported(): Identifier | undefined {
|
|
59
|
-
return unpackNode(global.generatedEs2panda._ExportSpecifierExportedConst(global.context, this.peer))
|
|
57
|
+
return unpackNode(global.generatedEs2panda._ExportSpecifierExportedConst(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_IDENTIFIER)
|
|
60
58
|
}
|
|
61
59
|
/** @deprecated */
|
|
62
60
|
setDefault(): this {
|
|
@@ -80,5 +78,5 @@ export function isExportSpecifier(node: object | undefined): node is ExportSpeci
|
|
|
80
78
|
return node instanceof ExportSpecifier
|
|
81
79
|
}
|
|
82
80
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER)) {
|
|
83
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER, (peer: KNativePointer) => new ExportSpecifier(peer))
|
|
81
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER, (peer: KNativePointer) => new ExportSpecifier(peer, Es2pandaAstNodeType.AST_NODE_TYPE_EXPORT_SPECIFIER))
|
|
84
82
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -33,13 +32,16 @@ import {
|
|
|
33
32
|
} from "../../reexport-for-generated"
|
|
34
33
|
|
|
35
34
|
import { AnnotatedExpression } from "./AnnotatedExpression"
|
|
35
|
+
import { Es2pandaAstNodeType } from "./../Es2pandaEnums"
|
|
36
36
|
import { Literal } from "./Literal"
|
|
37
37
|
import { TypeNode } from "./TypeNode"
|
|
38
38
|
import { TypedAstNode } from "./TypedAstNode"
|
|
39
|
+
import { extension_ExpressionGetPreferredTypePointer } from "./../../reexport-for-generated"
|
|
40
|
+
import { extension_ExpressionSetPreferredTypePointer } from "./../../reexport-for-generated"
|
|
39
41
|
|
|
40
42
|
export class Expression extends TypedAstNode {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
super(pointer)
|
|
43
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
44
|
+
super(pointer, astNodeType)
|
|
43
45
|
}
|
|
44
46
|
get isGrouped(): boolean {
|
|
45
47
|
return global.generatedEs2panda._ExpressionIsGroupedConst(global.context, this.peer)
|
|
@@ -73,6 +75,8 @@ export class Expression extends TypedAstNode {
|
|
|
73
75
|
get toString(): string {
|
|
74
76
|
return unpackString(global.generatedEs2panda._ExpressionToStringConst(global.context, this.peer))
|
|
75
77
|
}
|
|
78
|
+
getPreferredTypePointer = extension_ExpressionGetPreferredTypePointer
|
|
79
|
+
setPreferredTypePointer = extension_ExpressionSetPreferredTypePointer
|
|
76
80
|
protected readonly brandExpression: undefined
|
|
77
81
|
}
|
|
78
82
|
export function isExpression(node: object | undefined): node is Expression {
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -37,17 +36,16 @@ import { Expression } from "./Expression"
|
|
|
37
36
|
import { Statement } from "./Statement"
|
|
38
37
|
|
|
39
38
|
export class ExpressionStatement extends Statement {
|
|
40
|
-
constructor(pointer: KNativePointer) {
|
|
41
|
-
|
|
42
|
-
super(pointer)
|
|
39
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
40
|
+
super(pointer, astNodeType)
|
|
43
41
|
}
|
|
44
42
|
static createExpressionStatement(expr?: Expression): ExpressionStatement {
|
|
45
|
-
const result: ExpressionStatement = new ExpressionStatement(global.generatedEs2panda._CreateExpressionStatement(global.context, passNode(expr)))
|
|
43
|
+
const result: ExpressionStatement = new ExpressionStatement(global.generatedEs2panda._CreateExpressionStatement(global.context, passNode(expr)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT)
|
|
46
44
|
result.setChildrenParentPtr()
|
|
47
45
|
return result
|
|
48
46
|
}
|
|
49
47
|
static updateExpressionStatement(original?: ExpressionStatement, expr?: Expression): ExpressionStatement {
|
|
50
|
-
const result: ExpressionStatement = new ExpressionStatement(global.generatedEs2panda._UpdateExpressionStatement(global.context, passNode(original), passNode(expr)))
|
|
48
|
+
const result: ExpressionStatement = new ExpressionStatement(global.generatedEs2panda._UpdateExpressionStatement(global.context, passNode(original), passNode(expr)), Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT)
|
|
51
49
|
result.setChildrenParentPtr()
|
|
52
50
|
return result
|
|
53
51
|
}
|
|
@@ -65,5 +63,5 @@ export function isExpressionStatement(node: object | undefined): node is Express
|
|
|
65
63
|
return node instanceof ExpressionStatement
|
|
66
64
|
}
|
|
67
65
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT)) {
|
|
68
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT, (peer: KNativePointer) => new ExpressionStatement(peer))
|
|
66
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT, (peer: KNativePointer) => new ExpressionStatement(peer, Es2pandaAstNodeType.AST_NODE_TYPE_EXPRESSION_STATEMENT))
|
|
69
67
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,17 +37,16 @@ import { LoopStatement } from "./LoopStatement"
|
|
|
38
37
|
import { Statement } from "./Statement"
|
|
39
38
|
|
|
40
39
|
export class ForInStatement extends LoopStatement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createForInStatement(left?: AstNode, right?: Expression, body?: Statement): ForInStatement {
|
|
46
|
-
const result: ForInStatement = new ForInStatement(global.generatedEs2panda._CreateForInStatement(global.context, passNode(left), passNode(right), passNode(body)))
|
|
44
|
+
const result: ForInStatement = new ForInStatement(global.generatedEs2panda._CreateForInStatement(global.context, passNode(left), passNode(right), passNode(body)), Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateForInStatement(original?: ForInStatement, left?: AstNode, right?: Expression, body?: Statement): ForInStatement {
|
|
51
|
-
const result: ForInStatement = new ForInStatement(global.generatedEs2panda._UpdateForInStatement(global.context, passNode(original), passNode(left), passNode(right), passNode(body)))
|
|
49
|
+
const result: ForInStatement = new ForInStatement(global.generatedEs2panda._UpdateForInStatement(global.context, passNode(original), passNode(left), passNode(right), passNode(body)), Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
@@ -67,5 +65,5 @@ export function isForInStatement(node: object | undefined): node is ForInStateme
|
|
|
67
65
|
return node instanceof ForInStatement
|
|
68
66
|
}
|
|
69
67
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT)) {
|
|
70
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT, (peer: KNativePointer) => new ForInStatement(peer))
|
|
68
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT, (peer: KNativePointer) => new ForInStatement(peer, Es2pandaAstNodeType.AST_NODE_TYPE_FOR_IN_STATEMENT))
|
|
71
69
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,17 +37,16 @@ import { LoopStatement } from "./LoopStatement"
|
|
|
38
37
|
import { Statement } from "./Statement"
|
|
39
38
|
|
|
40
39
|
export class ForOfStatement extends LoopStatement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createForOfStatement(left: AstNode | undefined, right: Expression | undefined, body: Statement | undefined, isAwait: boolean): ForOfStatement {
|
|
46
|
-
const result: ForOfStatement = new ForOfStatement(global.generatedEs2panda._CreateForOfStatement(global.context, passNode(left), passNode(right), passNode(body), isAwait))
|
|
44
|
+
const result: ForOfStatement = new ForOfStatement(global.generatedEs2panda._CreateForOfStatement(global.context, passNode(left), passNode(right), passNode(body), isAwait), Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateForOfStatement(original: ForOfStatement | undefined, left: AstNode | undefined, right: Expression | undefined, body: Statement | undefined, isAwait: boolean): ForOfStatement {
|
|
51
|
-
const result: ForOfStatement = new ForOfStatement(global.generatedEs2panda._UpdateForOfStatement(global.context, passNode(original), passNode(left), passNode(right), passNode(body), isAwait))
|
|
49
|
+
const result: ForOfStatement = new ForOfStatement(global.generatedEs2panda._UpdateForOfStatement(global.context, passNode(original), passNode(left), passNode(right), passNode(body), isAwait), Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
@@ -70,5 +68,5 @@ export function isForOfStatement(node: object | undefined): node is ForOfStateme
|
|
|
70
68
|
return node instanceof ForOfStatement
|
|
71
69
|
}
|
|
72
70
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT)) {
|
|
73
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT, (peer: KNativePointer) => new ForOfStatement(peer))
|
|
71
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT, (peer: KNativePointer) => new ForOfStatement(peer, Es2pandaAstNodeType.AST_NODE_TYPE_FOR_OF_STATEMENT))
|
|
74
72
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,12 +37,11 @@ import { LoopStatement } from "./LoopStatement"
|
|
|
38
37
|
import { Statement } from "./Statement"
|
|
39
38
|
|
|
40
39
|
export class ForUpdateStatement extends LoopStatement {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static createForUpdateStatement(init?: AstNode, test?: Expression, update?: Expression, body?: Statement): ForUpdateStatement {
|
|
46
|
-
const result: ForUpdateStatement = new ForUpdateStatement(global.generatedEs2panda._CreateForUpdateStatement(global.context, passNode(init), passNode(test), passNode(update), passNode(body)))
|
|
44
|
+
const result: ForUpdateStatement = new ForUpdateStatement(global.generatedEs2panda._CreateForUpdateStatement(global.context, passNode(init), passNode(test), passNode(update), passNode(body)), Es2pandaAstNodeType.AST_NODE_TYPE_FOR_UPDATE_STATEMENT)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
@@ -65,5 +63,5 @@ export function isForUpdateStatement(node: object | undefined): node is ForUpdat
|
|
|
65
63
|
return node instanceof ForUpdateStatement
|
|
66
64
|
}
|
|
67
65
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_UPDATE_STATEMENT)) {
|
|
68
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_UPDATE_STATEMENT, (peer: KNativePointer) => new ForUpdateStatement(peer))
|
|
66
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FOR_UPDATE_STATEMENT, (peer: KNativePointer) => new ForUpdateStatement(peer, Es2pandaAstNodeType.AST_NODE_TYPE_FOR_UPDATE_STATEMENT))
|
|
69
67
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -33,43 +32,42 @@ import {
|
|
|
33
32
|
} from "../../reexport-for-generated"
|
|
34
33
|
|
|
35
34
|
import { AnnotationUsage } from "./AnnotationUsage"
|
|
36
|
-
import { Decorator } from "./Decorator"
|
|
37
35
|
import { Es2pandaAstNodeType } from "./../Es2pandaEnums"
|
|
38
36
|
import { ScriptFunction } from "./ScriptFunction"
|
|
37
|
+
import { SrcDumper } from "./SrcDumper"
|
|
39
38
|
import { Statement } from "./Statement"
|
|
40
39
|
|
|
41
40
|
export class FunctionDeclaration extends Statement {
|
|
42
|
-
constructor(pointer: KNativePointer) {
|
|
43
|
-
|
|
44
|
-
super(pointer)
|
|
41
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
42
|
+
super(pointer, astNodeType)
|
|
45
43
|
}
|
|
46
44
|
static createFunctionDeclaration(func: ScriptFunction | undefined, annotations: readonly AnnotationUsage[], isAnonymous: boolean): FunctionDeclaration {
|
|
47
|
-
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._CreateFunctionDeclaration(global.context, passNode(func), passNodeArray(annotations), annotations.length, isAnonymous))
|
|
45
|
+
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._CreateFunctionDeclaration(global.context, passNode(func), passNodeArray(annotations), annotations.length, isAnonymous), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION)
|
|
48
46
|
result.setChildrenParentPtr()
|
|
49
47
|
return result
|
|
50
48
|
}
|
|
51
49
|
static updateFunctionDeclaration(original: FunctionDeclaration | undefined, func: ScriptFunction | undefined, annotations: readonly AnnotationUsage[], isAnonymous: boolean): FunctionDeclaration {
|
|
52
|
-
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._UpdateFunctionDeclaration(global.context, passNode(original), passNode(func), passNodeArray(annotations), annotations.length, isAnonymous))
|
|
50
|
+
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._UpdateFunctionDeclaration(global.context, passNode(original), passNode(func), passNodeArray(annotations), annotations.length, isAnonymous), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION)
|
|
53
51
|
result.setChildrenParentPtr()
|
|
54
52
|
return result
|
|
55
53
|
}
|
|
56
54
|
static update1FunctionDeclaration(original: FunctionDeclaration | undefined, func: ScriptFunction | undefined, isAnonymous: boolean): FunctionDeclaration {
|
|
57
|
-
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._UpdateFunctionDeclaration1(global.context, passNode(original), passNode(func), isAnonymous))
|
|
55
|
+
const result: FunctionDeclaration = new FunctionDeclaration(global.generatedEs2panda._UpdateFunctionDeclaration1(global.context, passNode(original), passNode(func), isAnonymous), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION)
|
|
58
56
|
result.setChildrenParentPtr()
|
|
59
57
|
return result
|
|
60
58
|
}
|
|
61
59
|
get function(): ScriptFunction | undefined {
|
|
62
|
-
return unpackNode(global.generatedEs2panda._FunctionDeclarationFunction(global.context, this.peer))
|
|
60
|
+
return unpackNode(global.generatedEs2panda._FunctionDeclarationFunction(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_SCRIPT_FUNCTION)
|
|
63
61
|
}
|
|
64
62
|
get isAnonymous(): boolean {
|
|
65
63
|
return global.generatedEs2panda._FunctionDeclarationIsAnonymousConst(global.context, this.peer)
|
|
66
64
|
}
|
|
67
|
-
get
|
|
68
|
-
return
|
|
65
|
+
get hasAnnotations(): boolean {
|
|
66
|
+
return global.generatedEs2panda._FunctionDeclarationHasAnnotationsConst(global.context, this.peer)
|
|
69
67
|
}
|
|
70
68
|
/** @deprecated */
|
|
71
|
-
|
|
72
|
-
global.generatedEs2panda.
|
|
69
|
+
emplaceAnnotation(source?: AnnotationUsage): this {
|
|
70
|
+
global.generatedEs2panda._FunctionDeclarationEmplaceAnnotation(global.context, this.peer, passNode(source))
|
|
73
71
|
return this
|
|
74
72
|
}
|
|
75
73
|
/** @deprecated */
|
|
@@ -78,15 +76,15 @@ export class FunctionDeclaration extends Statement {
|
|
|
78
76
|
return this
|
|
79
77
|
}
|
|
80
78
|
/** @deprecated */
|
|
81
|
-
|
|
82
|
-
global.generatedEs2panda.
|
|
79
|
+
dumpAnnotations(dumper?: SrcDumper): this {
|
|
80
|
+
global.generatedEs2panda._FunctionDeclarationDumpAnnotationsConst(global.context, this.peer, passNode(dumper))
|
|
83
81
|
return this
|
|
84
82
|
}
|
|
85
83
|
get annotationsForUpdate(): readonly AnnotationUsage[] {
|
|
86
|
-
return unpackNodeArray(global.generatedEs2panda._FunctionDeclarationAnnotationsForUpdate(global.context, this.peer))
|
|
84
|
+
return unpackNodeArray(global.generatedEs2panda._FunctionDeclarationAnnotationsForUpdate(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_ANNOTATION_USAGE)
|
|
87
85
|
}
|
|
88
86
|
get annotations(): readonly AnnotationUsage[] {
|
|
89
|
-
return unpackNodeArray(global.generatedEs2panda._FunctionDeclarationAnnotations(global.context, this.peer))
|
|
87
|
+
return unpackNodeArray(global.generatedEs2panda._FunctionDeclarationAnnotations(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_ANNOTATION_USAGE)
|
|
90
88
|
}
|
|
91
89
|
/** @deprecated */
|
|
92
90
|
setAnnotations(annotationList: readonly AnnotationUsage[]): this {
|
|
@@ -98,16 +96,11 @@ export class FunctionDeclaration extends Statement {
|
|
|
98
96
|
global.generatedEs2panda._FunctionDeclarationSetAnnotations1(global.context, this.peer, passNodeArray(annotationList), annotationList.length)
|
|
99
97
|
return this
|
|
100
98
|
}
|
|
101
|
-
/** @deprecated */
|
|
102
|
-
addAnnotations(annotations?: AnnotationUsage): this {
|
|
103
|
-
global.generatedEs2panda._FunctionDeclarationAddAnnotations(global.context, this.peer, passNode(annotations))
|
|
104
|
-
return this
|
|
105
|
-
}
|
|
106
99
|
protected readonly brandFunctionDeclaration: undefined
|
|
107
100
|
}
|
|
108
101
|
export function isFunctionDeclaration(node: object | undefined): node is FunctionDeclaration {
|
|
109
102
|
return node instanceof FunctionDeclaration
|
|
110
103
|
}
|
|
111
104
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION)) {
|
|
112
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION, (peer: KNativePointer) => new FunctionDeclaration(peer))
|
|
105
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION, (peer: KNativePointer) => new FunctionDeclaration(peer, Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_DECLARATION))
|
|
113
106
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -38,33 +37,32 @@ import { Identifier } from "./Identifier"
|
|
|
38
37
|
import { ScriptFunction } from "./ScriptFunction"
|
|
39
38
|
|
|
40
39
|
export class FunctionExpression extends Expression {
|
|
41
|
-
constructor(pointer: KNativePointer) {
|
|
42
|
-
|
|
43
|
-
super(pointer)
|
|
40
|
+
constructor(pointer: KNativePointer, astNodeType: Es2pandaAstNodeType) {
|
|
41
|
+
super(pointer, astNodeType)
|
|
44
42
|
}
|
|
45
43
|
static create1FunctionExpression(namedExpr?: Identifier, func?: ScriptFunction): FunctionExpression {
|
|
46
|
-
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._CreateFunctionExpression1(global.context, passNode(namedExpr), passNode(func)))
|
|
44
|
+
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._CreateFunctionExpression1(global.context, passNode(namedExpr), passNode(func)), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION)
|
|
47
45
|
result.setChildrenParentPtr()
|
|
48
46
|
return result
|
|
49
47
|
}
|
|
50
48
|
static updateFunctionExpression(original?: FunctionExpression, func?: ScriptFunction): FunctionExpression {
|
|
51
|
-
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._UpdateFunctionExpression(global.context, passNode(original), passNode(func)))
|
|
49
|
+
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._UpdateFunctionExpression(global.context, passNode(original), passNode(func)), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION)
|
|
52
50
|
result.setChildrenParentPtr()
|
|
53
51
|
return result
|
|
54
52
|
}
|
|
55
53
|
static update1FunctionExpression(original?: FunctionExpression, namedExpr?: Identifier, func?: ScriptFunction): FunctionExpression {
|
|
56
|
-
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._UpdateFunctionExpression1(global.context, passNode(original), passNode(namedExpr), passNode(func)))
|
|
54
|
+
const result: FunctionExpression = new FunctionExpression(global.generatedEs2panda._UpdateFunctionExpression1(global.context, passNode(original), passNode(namedExpr), passNode(func)), Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION)
|
|
57
55
|
result.setChildrenParentPtr()
|
|
58
56
|
return result
|
|
59
57
|
}
|
|
60
58
|
get function(): ScriptFunction | undefined {
|
|
61
|
-
return unpackNode(global.generatedEs2panda._FunctionExpressionFunction(global.context, this.peer))
|
|
59
|
+
return unpackNode(global.generatedEs2panda._FunctionExpressionFunction(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_SCRIPT_FUNCTION)
|
|
62
60
|
}
|
|
63
61
|
get isAnonymous(): boolean {
|
|
64
62
|
return global.generatedEs2panda._FunctionExpressionIsAnonymousConst(global.context, this.peer)
|
|
65
63
|
}
|
|
66
64
|
get id(): Identifier | undefined {
|
|
67
|
-
return unpackNode(global.generatedEs2panda._FunctionExpressionId(global.context, this.peer))
|
|
65
|
+
return unpackNode(global.generatedEs2panda._FunctionExpressionId(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_IDENTIFIER)
|
|
68
66
|
}
|
|
69
67
|
protected readonly brandFunctionExpression: undefined
|
|
70
68
|
}
|
|
@@ -72,5 +70,5 @@ export function isFunctionExpression(node: object | undefined): node is Function
|
|
|
72
70
|
return node instanceof FunctionExpression
|
|
73
71
|
}
|
|
74
72
|
if (!nodeByType.has(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION)) {
|
|
75
|
-
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION, (peer: KNativePointer) => new FunctionExpression(peer))
|
|
73
|
+
nodeByType.set(Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION, (peer: KNativePointer) => new FunctionExpression(peer, Es2pandaAstNodeType.AST_NODE_TYPE_FUNCTION_EXPRESSION))
|
|
76
74
|
}
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
unpackNonNullableNode,
|
|
25
25
|
unpackNode,
|
|
26
26
|
unpackNodeArray,
|
|
27
|
-
assertValidPeer,
|
|
28
27
|
AstNode,
|
|
29
28
|
KNativePointer,
|
|
30
29
|
nodeByType,
|
|
@@ -32,6 +31,7 @@ import {
|
|
|
32
31
|
unpackString
|
|
33
32
|
} from "../../reexport-for-generated"
|
|
34
33
|
|
|
34
|
+
import { Es2pandaAstNodeType } from "./../Es2pandaEnums"
|
|
35
35
|
import { Expression } from "./Expression"
|
|
36
36
|
import { TSTypeParameterDeclaration } from "./TSTypeParameterDeclaration"
|
|
37
37
|
import { TypeNode } from "./TypeNode"
|
|
@@ -47,7 +47,7 @@ export class FunctionSignature extends ArktsObject {
|
|
|
47
47
|
return unpackNodeArray(global.generatedEs2panda._FunctionSignatureParams(global.context, this.peer))
|
|
48
48
|
}
|
|
49
49
|
get typeParams(): TSTypeParameterDeclaration | undefined {
|
|
50
|
-
return unpackNode(global.generatedEs2panda._FunctionSignatureTypeParams(global.context, this.peer))
|
|
50
|
+
return unpackNode(global.generatedEs2panda._FunctionSignatureTypeParams(global.context, this.peer), Es2pandaAstNodeType.AST_NODE_TYPE_TS_TYPE_PARAMETER_DECLARATION)
|
|
51
51
|
}
|
|
52
52
|
get returnType(): TypeNode | undefined {
|
|
53
53
|
return unpackNode(global.generatedEs2panda._FunctionSignatureReturnType(global.context, this.peer))
|
|
@@ -65,3 +65,6 @@ export class FunctionSignature extends ArktsObject {
|
|
|
65
65
|
}
|
|
66
66
|
protected readonly brandFunctionSignature: undefined
|
|
67
67
|
}
|
|
68
|
+
export function isFunctionSignature(node: object | undefined): node is FunctionSignature {
|
|
69
|
+
return node instanceof FunctionSignature
|
|
70
|
+
}
|