@idlizer/arktscgen 2.1.9-arktscgen-9 → 2.1.10-arktscgen-2
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 +115 -3
- package/build/libarkts-copy/native/mingw.cross +13 -0
- package/build/libarkts-copy/native/src/bridges.cc +58 -227
- package/build/libarkts-copy/native/src/common.cc +49 -8
- package/build/libarkts-copy/native/src/generated/bridges.cc +1641 -44
- package/build/libarkts-copy/package.json +11 -14
- package/build/libarkts-copy/src/Es2pandaNativeModule.ts +28 -51
- package/build/libarkts-copy/src/arkts-api/ImportStorage.ts +1 -1
- package/build/libarkts-copy/src/arkts-api/class-by-peer.ts +6 -5
- package/build/libarkts-copy/src/arkts-api/factory/nodeFactory.ts +5 -2
- package/build/libarkts-copy/src/arkts-api/node-cache.ts +4 -0
- 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/peers/AstNode.ts +8 -6
- 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/arkts-api/static/global.ts +28 -1
- package/build/libarkts-copy/src/arkts-api/utilities/extensions.ts +46 -6
- package/build/libarkts-copy/src/arkts-api/utilities/private.ts +3 -3
- package/build/libarkts-copy/src/arkts-api/utilities/public.ts +58 -90
- package/build/libarkts-copy/src/arkts-api/visitor.ts +965 -365
- package/build/libarkts-copy/src/generated/Es2pandaEnums.ts +5 -0
- package/build/libarkts-copy/src/generated/Es2pandaNativeModule.ts +601 -13
- package/build/libarkts-copy/src/generated/index.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/AnnotatedAstNode.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/AnnotatedExpression.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/AnnotatedStatement.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/AnnotationDeclaration.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/AnnotationUsage.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ArkTsConfig.ts +4 -0
- package/build/libarkts-copy/src/generated/peers/ArrayExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ArrowFunctionExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/AssertStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/AssignmentExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/AstDumper.ts +3 -0
- package/build/libarkts-copy/src/generated/peers/AwaitExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BigIntLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BinaryExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BlockExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BlockStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BooleanLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/BreakStatement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/CallExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/CatchClause.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ChainExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/CharLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ClassDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ClassDefinition.ts +9 -8
- package/build/libarkts-copy/src/generated/peers/ClassElement.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/ClassExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ClassProperty.ts +15 -8
- package/build/libarkts-copy/src/generated/peers/ClassStaticBlock.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ConditionalExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ContinueStatement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/DebuggerStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/Decorator.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/DirectEvalExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/DoWhileStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSClassLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSFunctionType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSImportDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSIntrinsicNode.ts +7 -8
- package/build/libarkts-copy/src/generated/peers/ETSKeyofType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSModule.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSNewArrayInstanceExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSNewClassInstanceExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ETSNewMultiDimArrayInstanceExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ETSNullType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSPackageDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSParameterExpression.ts +7 -8
- package/build/libarkts-copy/src/generated/peers/ETSPrimitiveType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSReExportDeclaration.ts +3 -4
- package/build/libarkts-copy/src/generated/peers/ETSStringLiteralType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSStructDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSTuple.ts +9 -10
- package/build/libarkts-copy/src/generated/peers/ETSTypeReference.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSTypeReferencePart.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ETSUndefinedType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSUnionType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ETSWildcardType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/EmptyStatement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ExportAllDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ExportDefaultDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ExportNamedDeclaration.ts +9 -10
- package/build/libarkts-copy/src/generated/peers/ExportSpecifier.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/Expression.ts +7 -2
- package/build/libarkts-copy/src/generated/peers/ExpressionStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ForInStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ForOfStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ForUpdateStatement.ts +4 -5
- package/build/libarkts-copy/src/generated/peers/FunctionDeclaration.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/FunctionExpression.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/FunctionSignature.ts +3 -0
- package/build/libarkts-copy/src/generated/peers/Identifier.ts +7 -8
- package/build/libarkts-copy/src/generated/peers/IfStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ImportDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ImportDefaultSpecifier.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ImportExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ImportNamespaceSpecifier.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ImportSpecifier.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/LabelledStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/Literal.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/LoopStatement.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/MaybeOptionalExpression.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/MemberExpression.ts +5 -10
- package/build/libarkts-copy/src/generated/peers/MetaProperty.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/MethodDefinition.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/NamedType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/NewExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/NullLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/NumberLiteral.ts +10 -9
- package/build/libarkts-copy/src/generated/peers/ObjectExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/OmittedExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/OpaqueTypeNode.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/OverloadDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/PrefixAssertionExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/Property.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/RegExpLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ReturnStatement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/ScriptFunction.ts +7 -6
- package/build/libarkts-copy/src/generated/peers/SequenceExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/SourcePosition.ts +6 -0
- package/build/libarkts-copy/src/generated/peers/SpreadElement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/SrcDumper.ts +3 -0
- package/build/libarkts-copy/src/generated/peers/Statement.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/StringLiteral.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/SuperExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/SwitchCaseStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/SwitchStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSAnyKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSArrayType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSAsExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSBigintKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSBooleanKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSClassImplements.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TSConditionalType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSConstructorType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSEnumDeclaration.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TSEnumMember.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TSExternalModuleReference.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSFunctionType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSImportEqualsDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSImportType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSIndexSignature.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSIndexedAccessType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSInferType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSInterfaceBody.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSInterfaceDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSInterfaceHeritage.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSIntersectionType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSLiteralType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSMappedType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSMethodSignature.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSModuleBlock.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSModuleDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSNamedTupleMember.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSNeverKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSNonNullExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSNullKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSNumberKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSObjectKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSParameterProperty.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSParenthesizedType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSPropertySignature.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSQualifiedName.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSSignatureDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSStringKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSThisType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTupleType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeAliasDeclaration.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeAssertion.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeOperator.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeParameter.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TSTypeParameterDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeParameterInstantiation.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypePredicate.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeQuery.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSTypeReference.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSUndefinedKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSUnionType.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSUnknownKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TSVoidKeyword.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TaggedTemplateExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TemplateElement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TemplateLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ThisExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ThrowStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/TryStatement.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/TypeNode.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/TypedAstNode.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/TypedStatement.ts +3 -2
- package/build/libarkts-copy/src/generated/peers/TypeofExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/UnaryExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/UndefinedLiteral.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/UpdateExpression.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/ValidationInfo.ts +3 -0
- package/build/libarkts-copy/src/generated/peers/VariableDeclaration.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/VariableDeclarator.ts +6 -7
- package/build/libarkts-copy/src/generated/peers/WhileStatement.ts +5 -6
- package/build/libarkts-copy/src/generated/peers/YieldExpression.ts +5 -6
- package/build/libarkts-copy/src/index.ts +2 -0
- package/build/libarkts-copy/src/plugin-utils.ts +8 -1
- package/build/libarkts-copy/src/reexport-for-generated.ts +8 -0
- package/build/libarkts-copy/src/tracer.ts +172 -0
- package/lib/index.js +1357 -510
- package/package.json +2 -2
- 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/AstNode.ts +0 -26
- 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/performance.ts +0 -190
- 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
|
@@ -23,13 +23,73 @@
|
|
|
23
23
|
],
|
|
24
24
|
"ignore": {
|
|
25
25
|
"full": [
|
|
26
|
-
"es2panda_Impl",
|
|
27
26
|
"es2panda_Config",
|
|
28
27
|
"es2panda_ExternalSource",
|
|
29
28
|
"es2panda_OverloadInfo",
|
|
30
|
-
"es2panda_GlobalContext"
|
|
29
|
+
"es2panda_GlobalContext",
|
|
30
|
+
|
|
31
|
+
// Duplicates of types in ir namespace
|
|
32
|
+
// They will be removed in the fututre.
|
|
33
|
+
'es2panda_Signature',
|
|
34
|
+
'es2panda_CheckerContext',
|
|
35
|
+
'es2panda_Type',
|
|
36
|
+
'es2panda_TypeRelation',
|
|
37
|
+
'es2panda_GlobalTypesHolder',
|
|
38
|
+
'es2panda_Variable',
|
|
39
|
+
'es2panda_Scope',
|
|
40
|
+
'es2panda_Path',
|
|
41
|
+
'es2panda_ResolveResult',
|
|
42
|
+
'es2panda_RecordTable',
|
|
43
|
+
'es2panda_BoundContext',
|
|
44
|
+
'es2panda_ImportPathManager',
|
|
45
|
+
'es2panda_Options',
|
|
46
|
+
'es2panda_AstNode',
|
|
47
|
+
'es2panda_Program',
|
|
48
|
+
'es2panda_ArkTsConfig',
|
|
49
|
+
'es2panda_FunctionSignature',
|
|
50
|
+
|
|
51
|
+
'NodeTransformer',
|
|
52
|
+
'NodeTraverser',
|
|
53
|
+
'AstNodeForEachFunction',
|
|
54
|
+
'ClassBuilder',
|
|
55
|
+
'ClassInitializerBuilder',
|
|
56
|
+
'MethodBuilder',
|
|
57
|
+
'NodePredicate',
|
|
58
|
+
'PropertyProcessor',
|
|
59
|
+
'PropertyTraverser',
|
|
60
|
+
|
|
61
|
+
'checker.*',
|
|
62
|
+
'varbinder.*',
|
|
63
|
+
'parser.*',
|
|
64
|
+
'util.*',
|
|
65
|
+
'gen.*',
|
|
66
|
+
'es2panda.*',
|
|
67
|
+
'ast_verifier.*',
|
|
68
|
+
|
|
69
|
+
'parser.Program!',
|
|
70
|
+
'es2panda.ArkTsConfig!',
|
|
71
|
+
// Do not support node type
|
|
72
|
+
//'varbinder.FunctionDecl!',
|
|
73
|
+
//'varbinder.InterfaceDecl!',
|
|
74
|
+
// MemberExpression has checker.ETSFunctionType ExtensionAccessorTypeConst(es2panda_Context context);
|
|
75
|
+
//'checker.ETSFunctionType!',
|
|
76
|
+
//'ir.ETSFunctionType',
|
|
77
|
+
|
|
78
|
+
'ir.Annotated',
|
|
79
|
+
'ir.AnnotationAllowed',
|
|
80
|
+
'ir.Typed',
|
|
81
|
+
'ir.VectorIterationGuard',
|
|
82
|
+
|
|
83
|
+
'VoidPtr',
|
|
31
84
|
],
|
|
32
85
|
"partial": [
|
|
86
|
+
{
|
|
87
|
+
interface: "es2panda_Impl",
|
|
88
|
+
methods: [
|
|
89
|
+
"LogSyntaxError", "LogWarning", "LogTypeError", // wrong idl
|
|
90
|
+
"DestroyContext", // cleanup arena (Improve: move this cleanup to another method)
|
|
91
|
+
],
|
|
92
|
+
},
|
|
33
93
|
{
|
|
34
94
|
interface: "MethodDefinition",
|
|
35
95
|
methods: [
|
|
@@ -306,6 +366,32 @@
|
|
|
306
366
|
name: "setPreferredReturnTypePointer",
|
|
307
367
|
definition: "extension_ScriptFunctionSetPreferredReturnTypePointer",
|
|
308
368
|
},
|
|
369
|
+
{
|
|
370
|
+
name: "setParams",
|
|
371
|
+
definition: "extension_ScriptFunctionSetParams",
|
|
372
|
+
},
|
|
373
|
+
]
|
|
374
|
+
},
|
|
375
|
+
{
|
|
376
|
+
interface: "ClassDefinition",
|
|
377
|
+
methods: [
|
|
378
|
+
{
|
|
379
|
+
name: "setBody",
|
|
380
|
+
definition: "extension_ClassDefinitionSetBody",
|
|
381
|
+
},
|
|
382
|
+
]
|
|
383
|
+
},
|
|
384
|
+
{
|
|
385
|
+
interface: "Expression",
|
|
386
|
+
methods: [
|
|
387
|
+
{
|
|
388
|
+
name: "getPreferredTypePointer",
|
|
389
|
+
definition: "extension_ExpressionGetPreferredTypePointer",
|
|
390
|
+
},
|
|
391
|
+
{
|
|
392
|
+
name: "setPreferredTypePointer",
|
|
393
|
+
definition: "extension_ExpressionSetPreferredTypePointer",
|
|
394
|
+
},
|
|
309
395
|
]
|
|
310
396
|
},
|
|
311
397
|
{
|
|
@@ -316,7 +402,33 @@
|
|
|
316
402
|
definition: "extension_ProgramGetExternalSources",
|
|
317
403
|
},
|
|
318
404
|
],
|
|
319
|
-
}
|
|
405
|
+
},
|
|
406
|
+
{
|
|
407
|
+
interface: "es2panda_SourcePosition",
|
|
408
|
+
methods: [
|
|
409
|
+
{
|
|
410
|
+
name: "getLine",
|
|
411
|
+
definition: "extension_SourcePositionGetLine",
|
|
412
|
+
},
|
|
413
|
+
{
|
|
414
|
+
name: "getCol",
|
|
415
|
+
definition: "extension_SourcePositionGetCol",
|
|
416
|
+
},
|
|
417
|
+
{
|
|
418
|
+
name: "toString",
|
|
419
|
+
definition: "extension_SourcePositionToString",
|
|
420
|
+
},
|
|
421
|
+
],
|
|
422
|
+
},
|
|
423
|
+
{
|
|
424
|
+
interface: "NumberLiteral",
|
|
425
|
+
methods: [
|
|
426
|
+
{
|
|
427
|
+
name: "value",
|
|
428
|
+
definition: "extension_NumberLiteralValue",
|
|
429
|
+
},
|
|
430
|
+
],
|
|
431
|
+
},
|
|
320
432
|
],
|
|
321
433
|
parameters: [
|
|
322
434
|
{
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
# Copyright (c) 2025 Huawei Device Co., Ltd.
|
|
2
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
|
+
# you may not use this file except in compliance with the License.
|
|
4
|
+
# You may obtain a copy of the License at
|
|
5
|
+
#
|
|
6
|
+
# http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
#
|
|
8
|
+
# Unless required by applicable law or agreed to in writing, software
|
|
9
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
10
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
|
+
# See the License for the specific language governing permissions and
|
|
12
|
+
# limitations under the License.
|
|
13
|
+
|
|
1
14
|
[binaries]
|
|
2
15
|
c = 'x86_64-w64-mingw32-gcc'
|
|
3
16
|
cpp = 'x86_64-w64-mingw32-g++'
|
|
@@ -19,15 +19,6 @@
|
|
|
19
19
|
#include <string>
|
|
20
20
|
#include <mutex>
|
|
21
21
|
|
|
22
|
-
KNativePointer impl_AstNodeRecheck(KNativePointer contextPtr, KNativePointer nodePtr)
|
|
23
|
-
{
|
|
24
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
25
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
26
|
-
GetImpl()->AstNodeRecheck(context, node);
|
|
27
|
-
return nullptr;
|
|
28
|
-
}
|
|
29
|
-
KOALA_INTEROP_2(AstNodeRecheck, KNativePointer, KNativePointer, KNativePointer)
|
|
30
|
-
|
|
31
22
|
KNativePointer impl_AstNodeRebind(KNativePointer contextPtr, KNativePointer nodePtr)
|
|
32
23
|
{
|
|
33
24
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -57,17 +48,6 @@ KNativePointer impl_AnnotationAllowedAnnotationsConst(KNativePointer contextPtr,
|
|
|
57
48
|
}
|
|
58
49
|
KOALA_INTEROP_3(AnnotationAllowedAnnotationsConst, KNativePointer, KNativePointer, KNativePointer, KNativePointer)
|
|
59
50
|
|
|
60
|
-
/*
|
|
61
|
-
KNativePointer impl_AstNodeVariableConst(KNativePointer contextPtr, KNativePointer nodePtr)
|
|
62
|
-
{
|
|
63
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
64
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
65
|
-
|
|
66
|
-
return GetImpl()->AstNodeVariableConst(context, node);
|
|
67
|
-
}
|
|
68
|
-
KOALA_INTEROP_2(AstNodeVariableConst, KNativePointer, KNativePointer, KNativePointer)
|
|
69
|
-
*/
|
|
70
|
-
|
|
71
51
|
KNativePointer impl_VariableDeclaration(KNativePointer contextPtr, KNativePointer variablePtr)
|
|
72
52
|
{
|
|
73
53
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -86,15 +66,6 @@ KNativePointer impl_DeclNode(KNativePointer contextPtr, KNativePointer declPtr)
|
|
|
86
66
|
}
|
|
87
67
|
KOALA_INTEROP_2(DeclNode, KNativePointer, KNativePointer, KNativePointer)
|
|
88
68
|
|
|
89
|
-
/*
|
|
90
|
-
KNativePointer impl_AstNodeScopeConst(KNativePointer contextPtr, KNativePointer nodePtr)
|
|
91
|
-
{
|
|
92
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
93
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
94
|
-
return GetImpl()->AstNodeScopeConst(context, node);
|
|
95
|
-
}
|
|
96
|
-
KOALA_INTEROP_2(AstNodeScopeConst, KNativePointer, KNativePointer, KNativePointer)
|
|
97
|
-
*/
|
|
98
69
|
KNativePointer impl_ScopeSetParent(KNativePointer contextPtr, KNativePointer nodePtr, KNativePointer parentPtr)
|
|
99
70
|
{
|
|
100
71
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -105,16 +76,6 @@ KNativePointer impl_ScopeSetParent(KNativePointer contextPtr, KNativePointer nod
|
|
|
105
76
|
}
|
|
106
77
|
KOALA_INTEROP_3(ScopeSetParent, KNativePointer, KNativePointer, KNativePointer, KNativePointer)
|
|
107
78
|
|
|
108
|
-
/*
|
|
109
|
-
KNativePointer impl_CreateNumberLiteral(KNativePointer contextPtr, KDouble value)
|
|
110
|
-
{
|
|
111
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
112
|
-
|
|
113
|
-
return GetImpl()->CreateNumberLiteral(context, value);
|
|
114
|
-
}
|
|
115
|
-
KOALA_INTEROP_2(CreateNumberLiteral, KNativePointer, KNativePointer, KDouble)
|
|
116
|
-
*/
|
|
117
|
-
|
|
118
79
|
KNativePointer impl_ETSParserCreateExpression(KNativePointer contextPtr, KStringPtr& sourceCodePtr, KInt flagsT)
|
|
119
80
|
{
|
|
120
81
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -124,42 +85,6 @@ KNativePointer impl_ETSParserCreateExpression(KNativePointer contextPtr, KString
|
|
|
124
85
|
}
|
|
125
86
|
KOALA_INTEROP_3(ETSParserCreateExpression, KNativePointer, KNativePointer, KStringPtr, KInt)
|
|
126
87
|
|
|
127
|
-
KBoolean impl_IsProgram(KNativePointer contextPtr, KNativePointer nodePtr)
|
|
128
|
-
{
|
|
129
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
130
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
131
|
-
return GetImpl()->AstNodeIsProgramConst(context, node);
|
|
132
|
-
}
|
|
133
|
-
KOALA_INTEROP_2(IsProgram, KBoolean, KNativePointer, KNativePointer)
|
|
134
|
-
|
|
135
|
-
KBoolean impl_IsBlockStatement(KNativePointer nodePtr)
|
|
136
|
-
{
|
|
137
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
138
|
-
return GetImpl()->IsBlockStatement(node);
|
|
139
|
-
}
|
|
140
|
-
KOALA_INTEROP_1(IsBlockStatement, KBoolean, KNativePointer)
|
|
141
|
-
|
|
142
|
-
KNativePointer impl_ProceedToState(KNativePointer contextPtr, KInt state)
|
|
143
|
-
{
|
|
144
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
145
|
-
return GetImpl()->ProceedToState(context, intToState(state));
|
|
146
|
-
}
|
|
147
|
-
KOALA_INTEROP_2(ProceedToState, KNativePointer, KNativePointer, KInt)
|
|
148
|
-
|
|
149
|
-
KNativePointer impl_ContextProgram(KNativePointer contextPtr)
|
|
150
|
-
{
|
|
151
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
152
|
-
return GetImpl()->ContextProgram(context);
|
|
153
|
-
}
|
|
154
|
-
KOALA_INTEROP_1(ContextProgram, KNativePointer, KNativePointer)
|
|
155
|
-
|
|
156
|
-
KBoolean impl_IsIdentifier(KNativePointer nodePtr)
|
|
157
|
-
{
|
|
158
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
159
|
-
return GetImpl()->IsIdentifier(node);
|
|
160
|
-
}
|
|
161
|
-
KOALA_INTEROP_1(IsIdentifier, KBoolean, KNativePointer)
|
|
162
|
-
|
|
163
88
|
KNativePointer impl_CreateContextFromString(KNativePointer configPtr, KStringPtr& sourcePtr, KStringPtr& filenamePtr)
|
|
164
89
|
{
|
|
165
90
|
auto config = reinterpret_cast<es2panda_Config*>(configPtr);
|
|
@@ -174,40 +99,6 @@ KNativePointer impl_CreateContextFromFile(KNativePointer configPtr, KStringPtr&
|
|
|
174
99
|
}
|
|
175
100
|
KOALA_INTEROP_2(CreateContextFromFile, KNativePointer, KNativePointer, KStringPtr)
|
|
176
101
|
|
|
177
|
-
KInt impl_ContextState(KNativePointer contextPtr)
|
|
178
|
-
{
|
|
179
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
180
|
-
|
|
181
|
-
return static_cast<KInt>(GetImpl()->ContextState(context));
|
|
182
|
-
}
|
|
183
|
-
KOALA_INTEROP_1(ContextState, KInt, KNativePointer)
|
|
184
|
-
|
|
185
|
-
KNativePointer impl_ContextErrorMessage(KNativePointer contextPtr)
|
|
186
|
-
{
|
|
187
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
188
|
-
|
|
189
|
-
return StageArena::strdup(GetImpl()->ContextErrorMessage(context));
|
|
190
|
-
}
|
|
191
|
-
KOALA_INTEROP_1(ContextErrorMessage, KNativePointer, KNativePointer)
|
|
192
|
-
|
|
193
|
-
KNativePointer impl_GetAllErrorMessages(KNativePointer contextPtr)
|
|
194
|
-
{
|
|
195
|
-
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
196
|
-
|
|
197
|
-
return StageArena::strdup(GetImpl()->GetAllErrorMessages(context));
|
|
198
|
-
}
|
|
199
|
-
KOALA_INTEROP_1(GetAllErrorMessages, KNativePointer, KNativePointer)
|
|
200
|
-
|
|
201
|
-
/*
|
|
202
|
-
KNativePointer impl_CallExpressionSignature(KNativePointer context, KNativePointer classInstance)
|
|
203
|
-
{
|
|
204
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
205
|
-
const auto _classInstance = reinterpret_cast<es2panda_AstNode*>(classInstance);
|
|
206
|
-
const auto result = GetImpl()->CallExpressionSignature(_context, _classInstance);
|
|
207
|
-
return result;
|
|
208
|
-
}
|
|
209
|
-
KOALA_INTEROP_2(CallExpressionSignature, KNativePointer, KNativePointer, KNativePointer)
|
|
210
|
-
*/
|
|
211
102
|
KNativePointer impl_SignatureFunction(KNativePointer context, KNativePointer classInstance)
|
|
212
103
|
{
|
|
213
104
|
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -217,15 +108,6 @@ KNativePointer impl_SignatureFunction(KNativePointer context, KNativePointer cla
|
|
|
217
108
|
}
|
|
218
109
|
KOALA_INTEROP_2(SignatureFunction, KNativePointer, KNativePointer, KNativePointer)
|
|
219
110
|
|
|
220
|
-
KNativePointer impl_DeclarationFromIdentifier(KNativePointer context, KNativePointer identifier)
|
|
221
|
-
{
|
|
222
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
223
|
-
const auto _identifier = reinterpret_cast<es2panda_AstNode*>(identifier);
|
|
224
|
-
const auto result = GetImpl()->DeclarationFromIdentifier(_context, _identifier);
|
|
225
|
-
return result;
|
|
226
|
-
}
|
|
227
|
-
KOALA_INTEROP_2(DeclarationFromIdentifier, KNativePointer, KNativePointer, KNativePointer)
|
|
228
|
-
|
|
229
111
|
static KNativePointer impl_ProgramExternalSources(KNativePointer contextPtr, KNativePointer instancePtr)
|
|
230
112
|
{
|
|
231
113
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -272,27 +154,6 @@ static KNativePointer impl_ExternalSourcePrograms(KNativePointer instance)
|
|
|
272
154
|
}
|
|
273
155
|
KOALA_INTEROP_1(ExternalSourcePrograms, KNativePointer, KNativePointer);
|
|
274
156
|
|
|
275
|
-
KBoolean impl_IsClassProperty(KNativePointer nodePtr)
|
|
276
|
-
{
|
|
277
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
278
|
-
return GetImpl()->IsClassProperty(node);
|
|
279
|
-
}
|
|
280
|
-
KOALA_INTEROP_1(IsClassProperty, KBoolean, KNativePointer)
|
|
281
|
-
|
|
282
|
-
KBoolean impl_IsETSUnionType(KNativePointer nodePtr)
|
|
283
|
-
{
|
|
284
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
285
|
-
return GetImpl()->IsETSUnionType(node);
|
|
286
|
-
}
|
|
287
|
-
KOALA_INTEROP_1(IsETSUnionType, KBoolean, KNativePointer)
|
|
288
|
-
|
|
289
|
-
KBoolean impl_IsETSFunctionType(KNativePointer nodePtr)
|
|
290
|
-
{
|
|
291
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
292
|
-
return GetImpl()->IsETSFunctionType(node);
|
|
293
|
-
}
|
|
294
|
-
KOALA_INTEROP_1(IsETSFunctionType, KBoolean, KNativePointer)
|
|
295
|
-
|
|
296
157
|
KNativePointer impl_ETSParserBuildImportDeclaration(KNativePointer context, KInt importKinds, KNativePointerArray specifiers, KUInt specifiersSequenceLength, KNativePointer source, KNativePointer program, KInt importFlag)
|
|
297
158
|
{
|
|
298
159
|
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -307,15 +168,6 @@ KNativePointer impl_ETSParserBuildImportDeclaration(KNativePointer context, KInt
|
|
|
307
168
|
}
|
|
308
169
|
KOALA_INTEROP_7(ETSParserBuildImportDeclaration, KNativePointer, KNativePointer, KInt, KNativePointerArray, KUInt, KNativePointer, KNativePointer, KInt)
|
|
309
170
|
|
|
310
|
-
void impl_InsertETSImportDeclarationAndParse(KNativePointer context, KNativePointer program, KNativePointer importDeclaration)
|
|
311
|
-
{
|
|
312
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
313
|
-
const auto _program = reinterpret_cast<es2panda_Program*>(program);
|
|
314
|
-
const auto _import = reinterpret_cast<es2panda_AstNode*>(importDeclaration);
|
|
315
|
-
GetImpl()->InsertETSImportDeclarationAndParse(_context, _program, _import);
|
|
316
|
-
}
|
|
317
|
-
KOALA_INTEROP_V3(InsertETSImportDeclarationAndParse, KNativePointer, KNativePointer, KNativePointer)
|
|
318
|
-
|
|
319
171
|
KNativePointer impl_ETSParserGetImportPathManager(KNativePointer contextPtr)
|
|
320
172
|
{
|
|
321
173
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -323,37 +175,13 @@ KNativePointer impl_ETSParserGetImportPathManager(KNativePointer contextPtr)
|
|
|
323
175
|
}
|
|
324
176
|
KOALA_INTEROP_1(ETSParserGetImportPathManager, KNativePointer, KNativePointer);
|
|
325
177
|
|
|
326
|
-
|
|
327
|
-
{
|
|
328
|
-
auto&& _context_ = reinterpret_cast<es2panda_Context *>(context);
|
|
329
|
-
return GetImpl()->CreateSourcePosition(_context_, index, line);
|
|
330
|
-
}
|
|
331
|
-
KOALA_INTEROP_3(CreateSourcePosition, KNativePointer, KNativePointer, KInt, KInt);
|
|
332
|
-
|
|
333
|
-
KInt impl_SourcePositionIndex(KNativePointer context, KNativePointer instance)
|
|
334
|
-
{
|
|
335
|
-
auto&& _context_ = reinterpret_cast<es2panda_Context *>(context);
|
|
336
|
-
auto&& _instance_ = reinterpret_cast<es2panda_SourcePosition *>(instance);
|
|
337
|
-
return GetImpl()->SourcePositionIndex(_context_, _instance_);
|
|
338
|
-
}
|
|
339
|
-
KOALA_INTEROP_2(SourcePositionIndex, KInt, KNativePointer, KNativePointer);
|
|
340
|
-
|
|
341
|
-
KInt impl_SourcePositionLine(KNativePointer context, KNativePointer instance)
|
|
178
|
+
KInt impl_SourcePositionCol(KNativePointer context, KNativePointer instance)
|
|
342
179
|
{
|
|
343
180
|
auto&& _context_ = reinterpret_cast<es2panda_Context *>(context);
|
|
344
181
|
auto&& _instance_ = reinterpret_cast<es2panda_SourcePosition *>(instance);
|
|
345
|
-
return GetImpl()->
|
|
182
|
+
return GetImpl()->SourcePositionCol(_context_, _instance_);
|
|
346
183
|
}
|
|
347
|
-
KOALA_INTEROP_2(
|
|
348
|
-
|
|
349
|
-
KNativePointer impl_CreateSourceRange(KNativePointer context, KNativePointer start, KNativePointer end)
|
|
350
|
-
{
|
|
351
|
-
auto&& _context_ = reinterpret_cast<es2panda_Context *>(context);
|
|
352
|
-
auto&& _start_ = reinterpret_cast<es2panda_SourcePosition *>(start);
|
|
353
|
-
auto&& _end_ = reinterpret_cast<es2panda_SourcePosition *>(end);
|
|
354
|
-
return GetImpl()->CreateSourceRange(_context_, _start_, _end_);
|
|
355
|
-
}
|
|
356
|
-
KOALA_INTEROP_3(CreateSourceRange, KNativePointer, KNativePointer, KNativePointer, KNativePointer);
|
|
184
|
+
KOALA_INTEROP_2(SourcePositionCol, KInt, KNativePointer, KNativePointer);
|
|
357
185
|
|
|
358
186
|
KNativePointer impl_ConfigGetOptions(KNativePointer config)
|
|
359
187
|
{
|
|
@@ -405,6 +233,14 @@ KOALA_INTEROP_V1(DestroyGlobalContext, KNativePointer)
|
|
|
405
233
|
// All these "Checker_" bridges are related to checker namespace in es2panda, so work with them carefully
|
|
406
234
|
// Checker.Type does reset on recheck, so modifying them makes no sence
|
|
407
235
|
// It seems that compiler does not provide API to convert Checker.Type to ir.Type
|
|
236
|
+
KNativePointer impl_Checker_CreateOpaqueTypeNode(KNativePointer context, KNativePointer type)
|
|
237
|
+
{
|
|
238
|
+
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
239
|
+
auto _type = reinterpret_cast<es2panda_Type*>(type);
|
|
240
|
+
return GetImpl()->CreateOpaqueTypeNode(_context, _type);
|
|
241
|
+
}
|
|
242
|
+
KOALA_INTEROP_2(Checker_CreateOpaqueTypeNode, KNativePointer, KNativePointer, KNativePointer)
|
|
243
|
+
|
|
408
244
|
KNativePointer impl_Checker_ScriptFunctionSignature(KNativePointer context, KNativePointer node)
|
|
409
245
|
{
|
|
410
246
|
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -449,6 +285,24 @@ void impl_Checker_ScriptFunctionSetPreferredReturnType(KNativePointer context, K
|
|
|
449
285
|
}
|
|
450
286
|
KOALA_INTEROP_V3(Checker_ScriptFunctionSetPreferredReturnType, KNativePointer, KNativePointer, KNativePointer)
|
|
451
287
|
|
|
288
|
+
KNativePointer impl_Checker_ExpressionGetPreferredType(KNativePointer context, KNativePointer node)
|
|
289
|
+
{
|
|
290
|
+
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
291
|
+
auto _node = reinterpret_cast<es2panda_AstNode*>(node);
|
|
292
|
+
return GetImpl()->ExpressionPreferredTypeConst(_context, _node);
|
|
293
|
+
}
|
|
294
|
+
KOALA_INTEROP_2(Checker_ExpressionGetPreferredType, KNativePointer, KNativePointer, KNativePointer)
|
|
295
|
+
|
|
296
|
+
void impl_Checker_ExpressionSetPreferredType(KNativePointer context, KNativePointer node, KNativePointer type)
|
|
297
|
+
{
|
|
298
|
+
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
299
|
+
auto _node = reinterpret_cast<es2panda_AstNode*>(node);
|
|
300
|
+
auto _type = reinterpret_cast<es2panda_Type*>(type);
|
|
301
|
+
GetImpl()->ExpressionSetPreferredType(_context, _node, _type);
|
|
302
|
+
return;
|
|
303
|
+
}
|
|
304
|
+
KOALA_INTEROP_V3(Checker_ExpressionSetPreferredType, KNativePointer, KNativePointer, KNativePointer)
|
|
305
|
+
|
|
452
306
|
KNativePointer impl_Checker_TypeToString(KNativePointer context, KNativePointer type)
|
|
453
307
|
{
|
|
454
308
|
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -458,6 +312,14 @@ KNativePointer impl_Checker_TypeToString(KNativePointer context, KNativePointer
|
|
|
458
312
|
}
|
|
459
313
|
KOALA_INTEROP_2(Checker_TypeToString, KNativePointer, KNativePointer, KNativePointer)
|
|
460
314
|
|
|
315
|
+
KNativePointer impl_Checker_TypeClone(KNativePointer context, KNativePointer type)
|
|
316
|
+
{
|
|
317
|
+
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
318
|
+
auto _type = reinterpret_cast<es2panda_Type*>(type);
|
|
319
|
+
return GetImpl()->TypeClone(_context, _type);
|
|
320
|
+
}
|
|
321
|
+
KOALA_INTEROP_2(Checker_TypeClone, KNativePointer, KNativePointer, KNativePointer)
|
|
322
|
+
|
|
461
323
|
KNativePointer impl_Checker_TypeNodeGetType(KNativePointer context, KNativePointer astNode)
|
|
462
324
|
{
|
|
463
325
|
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -512,12 +374,6 @@ KNativePointer impl_ClassVariableDeclaration(KNativePointer context, KNativePoin
|
|
|
512
374
|
}
|
|
513
375
|
KOALA_INTEROP_2(ClassVariableDeclaration, KNativePointer, KNativePointer, KNativePointer)
|
|
514
376
|
|
|
515
|
-
KBoolean impl_IsMethodDefinition(KNativePointer nodePtr)
|
|
516
|
-
{
|
|
517
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
518
|
-
return GetImpl()->IsMethodDefinition(node);
|
|
519
|
-
}
|
|
520
|
-
KOALA_INTEROP_1(IsMethodDefinition, KBoolean, KNativePointer)
|
|
521
377
|
KNativePointer impl_TSInterfaceBodyBodyPtr(KNativePointer context, KNativePointer receiver)
|
|
522
378
|
{
|
|
523
379
|
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -538,30 +394,6 @@ KNativePointer impl_AnnotationDeclarationPropertiesPtrConst(KNativePointer conte
|
|
|
538
394
|
}
|
|
539
395
|
KOALA_INTEROP_2(AnnotationDeclarationPropertiesPtrConst, KNativePointer, KNativePointer, KNativePointer);
|
|
540
396
|
|
|
541
|
-
KNativePointer impl_SourceRangeStart(KNativePointer context, KNativePointer range)
|
|
542
|
-
{
|
|
543
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
544
|
-
const auto _range = reinterpret_cast<es2panda_SourceRange*>(range);
|
|
545
|
-
auto result = GetImpl()->SourceRangeStart(_context, _range);
|
|
546
|
-
return result;
|
|
547
|
-
}
|
|
548
|
-
KOALA_INTEROP_2(SourceRangeStart, KNativePointer, KNativePointer, KNativePointer)
|
|
549
|
-
|
|
550
|
-
KNativePointer impl_SourceRangeEnd(KNativePointer context, KNativePointer range) {
|
|
551
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
552
|
-
const auto _range = reinterpret_cast<es2panda_SourceRange*>(range);
|
|
553
|
-
auto result = GetImpl()->SourceRangeEnd(_context, _range);
|
|
554
|
-
return result;
|
|
555
|
-
}
|
|
556
|
-
KOALA_INTEROP_2(SourceRangeEnd, KNativePointer, KNativePointer, KNativePointer)
|
|
557
|
-
|
|
558
|
-
KBoolean impl_IsArrayExpression(KNativePointer nodePtr)
|
|
559
|
-
{
|
|
560
|
-
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
561
|
-
return GetImpl()->IsArrayExpression(node);
|
|
562
|
-
}
|
|
563
|
-
KOALA_INTEROP_1(IsArrayExpression, KBoolean, KNativePointer)
|
|
564
|
-
|
|
565
397
|
KNativePointer impl_ETSParserGetGlobalProgramAbsName(KNativePointer contextPtr)
|
|
566
398
|
{
|
|
567
399
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
@@ -641,23 +473,6 @@ void impl_LogDiagnostic(KNativePointer context, KNativePointer kind, KStringArra
|
|
|
641
473
|
}
|
|
642
474
|
KOALA_INTEROP_V5(LogDiagnostic, KNativePointer, KNativePointer, KStringArray, KInt, KNativePointer)
|
|
643
475
|
|
|
644
|
-
void impl_LogDiagnosticWithSuggestion(KNativePointer context, KNativePointer diagnosticInfo,
|
|
645
|
-
KNativePointer suggestionInfo)
|
|
646
|
-
{
|
|
647
|
-
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
648
|
-
const auto _diagnosticInfo = reinterpret_cast<es2panda_DiagnosticInfo*>(diagnosticInfo);
|
|
649
|
-
const auto _suggestionInfo = reinterpret_cast<es2panda_SuggestionInfo*>(suggestionInfo);
|
|
650
|
-
GetImpl()->LogDiagnosticWithSuggestion(_context, _diagnosticInfo, _suggestionInfo);
|
|
651
|
-
}
|
|
652
|
-
KOALA_INTEROP_V3(LogDiagnosticWithSuggestion, KNativePointer, KNativePointer, KNativePointer)
|
|
653
|
-
|
|
654
|
-
KInt impl_GenerateStaticDeclarationsFromContext(KNativePointer contextPtr, KStringPtr &outputPath)
|
|
655
|
-
{
|
|
656
|
-
auto context = reinterpret_cast<es2panda_Context *>(contextPtr);
|
|
657
|
-
return GetImpl()->GenerateStaticDeclarationsFromContext(context, outputPath.data());
|
|
658
|
-
}
|
|
659
|
-
KOALA_INTEROP_2(GenerateStaticDeclarationsFromContext, KInt, KNativePointer, KStringPtr)
|
|
660
|
-
|
|
661
476
|
KNativePointer impl_AnnotationUsageIrPropertiesPtrConst(KNativePointer context, KNativePointer receiver)
|
|
662
477
|
{
|
|
663
478
|
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
@@ -700,11 +515,27 @@ KNativePointer impl_CreateContextGenerateAbcForExternalSourceFiles(
|
|
|
700
515
|
}
|
|
701
516
|
KOALA_INTEROP_3(CreateContextGenerateAbcForExternalSourceFiles, KNativePointer, KNativePointer, KInt, KStringArray)
|
|
702
517
|
|
|
703
|
-
|
|
518
|
+
KInt impl_GetCompilationMode(KNativePointer configPtr)
|
|
704
519
|
{
|
|
705
|
-
auto
|
|
706
|
-
auto
|
|
707
|
-
return
|
|
520
|
+
auto _config = reinterpret_cast<es2panda_Config *>(configPtr);
|
|
521
|
+
auto _options = const_cast<es2panda_Options *>(GetImpl()->ConfigGetOptions(_config));
|
|
522
|
+
return GetImpl()->OptionsUtilGetCompilationModeConst(nullptr, _options);
|
|
708
523
|
}
|
|
709
|
-
|
|
524
|
+
KOALA_INTEROP_1(GetCompilationMode, KInt, KNativePointer);
|
|
710
525
|
|
|
526
|
+
KNativePointer impl_CreateTypeNodeFromTsType(KNativePointer context, KNativePointer nodePtr)
|
|
527
|
+
{
|
|
528
|
+
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
529
|
+
const auto _nodePtr = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
530
|
+
auto _tsType = GetImpl()->TypedTsType(_context, _nodePtr);
|
|
531
|
+
if (_tsType == nullptr) {
|
|
532
|
+
_tsType = GetImpl()->ExpressionTsType(_context, _nodePtr);
|
|
533
|
+
}
|
|
534
|
+
if (_tsType == nullptr) {
|
|
535
|
+
return nullptr;
|
|
536
|
+
}
|
|
537
|
+
const auto _nodeTsType = reinterpret_cast<es2panda_Type*>(_tsType);
|
|
538
|
+
auto _typeAnnotation = GetImpl()->CreateOpaqueTypeNode(_context, _nodeTsType);
|
|
539
|
+
return _typeAnnotation;
|
|
540
|
+
}
|
|
541
|
+
KOALA_INTEROP_2(CreateTypeNodeFromTsType, KNativePointer, KNativePointer, KNativePointer);
|
|
@@ -191,11 +191,6 @@ es2panda_Impl *GetImplSlow()
|
|
|
191
191
|
return es2pandaImplementation;
|
|
192
192
|
}
|
|
193
193
|
|
|
194
|
-
es2panda_ContextState intToState(KInt state)
|
|
195
|
-
{
|
|
196
|
-
return es2panda_ContextState(state);
|
|
197
|
-
}
|
|
198
|
-
|
|
199
194
|
string getString(KStringPtr ptr)
|
|
200
195
|
{
|
|
201
196
|
return ptr.data();
|
|
@@ -273,6 +268,30 @@ KInt impl_IdentifierIdentifierFlags(KNativePointer contextPtr, KNativePointer no
|
|
|
273
268
|
}
|
|
274
269
|
KOALA_INTEROP_2(IdentifierIdentifierFlags, KInt, KNativePointer, KNativePointer)
|
|
275
270
|
|
|
271
|
+
void impl_ScriptFunctionSetParams(KNativePointer context, KNativePointer receiver, KNativePointerArray paramsList, KUInt paramsListLength) {
|
|
272
|
+
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
273
|
+
const auto _receiver = reinterpret_cast<es2panda_AstNode*>(receiver);
|
|
274
|
+
const auto _paramsList = reinterpret_cast<es2panda_AstNode**>(paramsList);
|
|
275
|
+
const auto _paramsListLength = static_cast<KUInt>(paramsListLength);
|
|
276
|
+
GetImpl()->ScriptFunctionClearParams(_context, _receiver);
|
|
277
|
+
for (size_t i = 0; i < _paramsListLength; i++) {
|
|
278
|
+
GetImpl()->ScriptFunctionEmplaceParams(_context, _receiver, _paramsList[i]);
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
KOALA_INTEROP_V4(ScriptFunctionSetParams, KNativePointer, KNativePointer, KNativePointerArray, KUInt)
|
|
282
|
+
|
|
283
|
+
void impl_ClassDefinitionSetBody(KNativePointer context, KNativePointer receiver, KNativePointerArray body, KUInt bodyLength) {
|
|
284
|
+
const auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
285
|
+
const auto _receiver = reinterpret_cast<es2panda_AstNode*>(receiver);
|
|
286
|
+
const auto _body = reinterpret_cast<es2panda_AstNode**>(body);
|
|
287
|
+
const auto _bodyLength = static_cast<KUInt>(bodyLength);
|
|
288
|
+
GetImpl()->ClassDefinitionClearBody(_context, _receiver);
|
|
289
|
+
for (size_t i = 0; i < _bodyLength; i++) {
|
|
290
|
+
GetImpl()->ClassDefinitionEmplaceBody(_context, _receiver, _body[i]);
|
|
291
|
+
}
|
|
292
|
+
}
|
|
293
|
+
KOALA_INTEROP_V4(ClassDefinitionSetBody, KNativePointer, KNativePointer, KNativePointerArray, KUInt)
|
|
294
|
+
|
|
276
295
|
/*
|
|
277
296
|
Improve: NOT FROM API (shouldn't be there)
|
|
278
297
|
-----------------------------------------------------------------------------------------------------------------------------
|
|
@@ -304,15 +323,37 @@ KNativePointer impl_AstNodeUpdateAll(KNativePointer contextPtr, KNativePointer p
|
|
|
304
323
|
}
|
|
305
324
|
KOALA_INTEROP_2(AstNodeUpdateAll, KNativePointer, KNativePointer, KNativePointer)
|
|
306
325
|
|
|
307
|
-
|
|
326
|
+
void impl_AstNodeSetChildrenParentPtr(KNativePointer contextPtr, KNativePointer nodePtr) {
|
|
308
327
|
auto context = reinterpret_cast<es2panda_Context*>(contextPtr);
|
|
309
328
|
auto node = reinterpret_cast<es2panda_AstNode*>(nodePtr);
|
|
310
329
|
cachedParentNode = node;
|
|
311
330
|
|
|
312
331
|
GetImpl()->AstNodeIterateConst(context, node, changeParent);
|
|
313
|
-
return node;
|
|
314
332
|
}
|
|
315
|
-
|
|
333
|
+
KOALA_INTEROP_V2(AstNodeSetChildrenParentPtr, KNativePointer, KNativePointer)
|
|
334
|
+
|
|
335
|
+
void impl_AstNodeOnUpdate(KNativePointer context, KNativePointer newNode, KNativePointer replacedNode) {
|
|
336
|
+
auto _context = reinterpret_cast<es2panda_Context*>(context);
|
|
337
|
+
auto _newNode = reinterpret_cast<es2panda_AstNode*>(newNode);
|
|
338
|
+
auto _replacedNode = reinterpret_cast<es2panda_AstNode*>(replacedNode);
|
|
339
|
+
|
|
340
|
+
// Assign original
|
|
341
|
+
auto _original = GetImpl()->AstNodeOriginalNodeConst(_context, _replacedNode);
|
|
342
|
+
if (!_original) {
|
|
343
|
+
_original = _replacedNode;
|
|
344
|
+
}
|
|
345
|
+
GetImpl()->AstNodeSetOriginalNode(_context, _newNode, _original);
|
|
346
|
+
|
|
347
|
+
// Assign new node parent
|
|
348
|
+
auto _parent = GetImpl()->AstNodeParent(_context, _replacedNode);
|
|
349
|
+
if (_parent) {
|
|
350
|
+
GetImpl()->AstNodeSetParent(_context, _newNode, _parent);
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
// Redirect children parent pointer to this node
|
|
354
|
+
impl_AstNodeSetChildrenParentPtr(context, newNode);
|
|
355
|
+
}
|
|
356
|
+
KOALA_INTEROP_V3(AstNodeOnUpdate, KNativePointer, KNativePointer, KNativePointer)
|
|
316
357
|
|
|
317
358
|
std::vector<void*> cachedChildren;
|
|
318
359
|
|