cgraphx 2.0.1 → 2.0.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/dist/.claude-template/FLOW-MAP.md +7 -5
- package/dist/.claude-template/commands/end.md +1 -1
- package/dist/.claude-template/skills/cgraphx-guide/SKILL.md +2 -1
- package/dist/.claude-template/skills/cgraphx-guide/how-to-use.html +4 -2
- package/dist/.claude-template/skills/cgraphx-guide/how-to-use.md +5 -2
- package/dist/.claude-template/skills/iboc-check/SKILL.md +116 -0
- package/dist/.claude-template/skills/iboc-check/filler-prompt.md +75 -0
- package/dist/.claude-template/skills/implementation/SKILL.md +7 -0
- package/dist/.claude-template/skills/init-project-guides/SKILL.md +1 -1
- package/dist/.claude-template/skills/run-api-test/references/db-verification.md +2 -2
- package/dist/.claude-template/skills/subagent-implement/SKILL.md +3 -2
- package/dist/.claude-template/skills/write-api/assets/template-request.bru +3 -3
- package/dist/.claude-template/skills/write-api/references/bru-format.md +6 -6
- package/dist/.claude-template/skills/write-delivery-guide/SKILL.md +97 -0
- package/dist/.claude-template/skills/write-delivery-guide/template-change-type.md +120 -0
- package/dist/.claude-template/skills/write-delivery-guide/template-multi-role-flow.md +148 -0
- package/dist/.claude-template/skills/write-unit-test-code/SKILL.md +23 -6
- package/dist/core/code/engine/cli/analyze-config.js +320 -0
- package/dist/core/code/engine/cli/analyze.js +1086 -0
- package/dist/core/code/engine/cli/cli-message.js +83 -0
- package/dist/core/code/engine/cli/detect-changes-format.js +58 -0
- package/dist/core/code/engine/cli/embedding-dims.js +43 -0
- package/dist/core/code/engine/cli/format-elapsed.js +12 -0
- package/dist/core/code/engine/cli/help-i18n.js +144 -0
- package/dist/core/code/engine/cli/i18n/en.js +110 -0
- package/dist/core/code/engine/cli/i18n/index.js +47 -0
- package/dist/core/code/engine/cli/i18n/resources.js +9 -0
- package/dist/core/code/engine/cli/i18n/zh-CN.js +110 -0
- package/dist/core/code/engine/cli/lazy-action.js +67 -0
- package/dist/core/code/engine/cli/optional-grammars.js +136 -0
- package/dist/core/code/engine/cli/resolve-invocation.js +76 -0
- package/dist/core/code/engine/cli/status.js +156 -0
- package/dist/core/code/engine/cli/tool.js +384 -0
- package/dist/core/code/engine/config/ignore-service.js +511 -0
- package/dist/core/code/engine/config/supported-languages.js +17 -0
- package/dist/core/code/engine/core/analysis-features.js +64 -0
- package/dist/core/code/engine/core/analyzer-identity.js +2171 -0
- package/dist/core/code/engine/core/git-staleness.js +180 -0
- package/dist/core/code/engine/core/graph/graph.js +180 -0
- package/dist/core/code/engine/core/graph/import-cycles.js +106 -0
- package/dist/core/code/engine/core/graph/types.js +2 -0
- package/dist/core/code/engine/core/index-freshness.js +12 -0
- package/dist/core/code/engine/core/ingestion/binding-accumulator.js +341 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/c-cpp.js +168 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/csharp.js +9 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/dart.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/go.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/jvm.js +54 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/php.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/python.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/ruby.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/rust.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/swift.js +8 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/configs/typescript-javascript.js +11 -0
- package/dist/core/code/engine/core/ingestion/call-extractors/generic.js +62 -0
- package/dist/core/code/engine/core/ingestion/call-processor.js +503 -0
- package/dist/core/code/engine/core/ingestion/call-routing.js +98 -0
- package/dist/core/code/engine/core/ingestion/call-types.js +3 -0
- package/dist/core/code/engine/core/ingestion/cfg/callee-cell-format.js +45 -0
- package/dist/core/code/engine/core/ingestion/cfg/cfg-builder.js +202 -0
- package/dist/core/code/engine/core/ingestion/cfg/collect.js +81 -0
- package/dist/core/code/engine/core/ingestion/cfg/control-dependence.js +185 -0
- package/dist/core/code/engine/core/ingestion/cfg/control-flow-context.js +130 -0
- package/dist/core/code/engine/core/ingestion/cfg/emit.js +646 -0
- package/dist/core/code/engine/core/ingestion/cfg/post-dominators.js +182 -0
- package/dist/core/code/engine/core/ingestion/cfg/reaching-def-reason-codec.js +139 -0
- package/dist/core/code/engine/core/ingestion/cfg/reaching-defs-graph.js +322 -0
- package/dist/core/code/engine/core/ingestion/cfg/reaching-defs.js +792 -0
- package/dist/core/code/engine/core/ingestion/cfg/synthetic-escape.js +305 -0
- package/dist/core/code/engine/core/ingestion/cfg/traversal-result.js +6 -0
- package/dist/core/code/engine/core/ingestion/cfg/types.js +14 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/c-cpp-harvest.js +545 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/c-cpp.js +590 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/call-site-harvest.js +356 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/csharp-harvest.js +593 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/csharp.js +871 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/dart-harvest.js +874 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/dart.js +840 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/go-harvest.js +625 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/go.js +642 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/java-harvest.js +517 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/java.js +816 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/kotlin-harvest.js +723 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/kotlin.js +813 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/php-harvest.js +630 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/php.js +725 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/python-harvest.js +776 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/python.js +562 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/ruby-harvest.js +591 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/ruby.js +760 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/rust-harvest.js +877 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/rust.js +562 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/scope-tree-harvest.js +120 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/swift-harvest.js +683 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/swift.js +791 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/typescript-harvest.js +1060 -0
- package/dist/core/code/engine/core/ingestion/cfg/visitors/typescript.js +587 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/c-cpp.js +77 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/csharp.js +24 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/dart.js +10 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/go.js +28 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/jvm.js +67 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/php.js +10 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/python.js +10 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/ruby.js +13 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/rust.js +10 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/swift.js +21 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/configs/typescript-javascript.js +31 -0
- package/dist/core/code/engine/core/ingestion/class-extractors/generic.js +144 -0
- package/dist/core/code/engine/core/ingestion/class-types.js +2 -0
- package/dist/core/code/engine/core/ingestion/cluster-enricher.js +174 -0
- package/dist/core/code/engine/core/ingestion/community-processor.js +604 -0
- package/dist/core/code/engine/core/ingestion/constants.js +26 -0
- package/dist/core/code/engine/core/ingestion/cpp-ue-preprocessor.js +263 -0
- package/dist/core/code/engine/core/ingestion/csharp-namespace-gate.js +133 -0
- package/dist/core/code/engine/core/ingestion/di-extractors/index.js +38 -0
- package/dist/core/code/engine/core/ingestion/di-extractors/spring.js +310 -0
- package/dist/core/code/engine/core/ingestion/emit-references.js +244 -0
- package/dist/core/code/engine/core/ingestion/entry-point-scoring.js +201 -0
- package/dist/core/code/engine/core/ingestion/export-detection.js +244 -0
- package/dist/core/code/engine/core/ingestion/field-extractor.js +29 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/c-cpp.js +107 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/csharp.js +124 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/dart.js +99 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/go.js +102 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/helpers.js +198 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/jvm.js +172 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/php.js +67 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/python.js +94 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/ruby.js +79 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/rust.js +55 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/swift.js +93 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/configs/typescript-javascript.js +59 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/generic.js +147 -0
- package/dist/core/code/engine/core/ingestion/field-extractors/typescript.js +266 -0
- package/dist/core/code/engine/core/ingestion/field-types.js +3 -0
- package/dist/core/code/engine/core/ingestion/filesystem-walker.js +136 -0
- package/dist/core/code/engine/core/ingestion/finalize-orchestrator.js +159 -0
- package/dist/core/code/engine/core/ingestion/framework-detection.js +432 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/analysis-features.js +38 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/annotation-arguments.js +234 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/aop-candidates.js +88 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/aop.js +487 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/auto-configuration.js +21 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/bean-candidates.js +189 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/bean-catalog.js +32 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/bean-factories.js +73 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/conditionals.js +323 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/config-bindings.js +119 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/di-metadata.js +385 -0
- package/dist/core/code/engine/core/ingestion/frameworks/spring/resource-injection.js +96 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/c-cpp.js +17 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/csharp.js +46 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/dart.js +59 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/go.js +30 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/jvm.js +73 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/php.js +19 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/python.js +45 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/ruby.js +20 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/rust.js +58 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/swift.js +94 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/configs/typescript-javascript.js +26 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/csharp.js +128 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/go.js +50 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/jvm.js +112 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/php.js +80 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/python.js +75 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/resolver-factory.js +36 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/ruby.js +20 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/rust.js +79 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/standard.js +180 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/types.js +7 -0
- package/dist/core/code/engine/core/ingestion/import-resolvers/utils.js +153 -0
- package/dist/core/code/engine/core/ingestion/import-target-adapter.js +99 -0
- package/dist/core/code/engine/core/ingestion/language-config.js +391 -0
- package/dist/core/code/engine/core/ingestion/language-provider.js +25 -0
- package/dist/core/code/engine/core/ingestion/languages/c/arity-metadata.js +98 -0
- package/dist/core/code/engine/core/ingestion/languages/c/arity.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/c/capture-side-channel.js +69 -0
- package/dist/core/code/engine/core/ingestion/languages/c/captures.js +189 -0
- package/dist/core/code/engine/core/ingestion/languages/c/header-scan.js +58 -0
- package/dist/core/code/engine/core/ingestion/languages/c/import-decomposer.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/c/import-target.js +103 -0
- package/dist/core/code/engine/core/ingestion/languages/c/index.js +33 -0
- package/dist/core/code/engine/core/ingestion/languages/c/interpret.js +53 -0
- package/dist/core/code/engine/core/ingestion/languages/c/merge-bindings.js +26 -0
- package/dist/core/code/engine/core/ingestion/languages/c/query.js +210 -0
- package/dist/core/code/engine/core/ingestion/languages/c/scope-resolver.js +112 -0
- package/dist/core/code/engine/core/ingestion/languages/c/simple-hooks.js +24 -0
- package/dist/core/code/engine/core/ingestion/languages/c/static-linkage.js +109 -0
- package/dist/core/code/engine/core/ingestion/languages/c-cpp.js +506 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/adl.js +804 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/arity-metadata.js +258 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/arity.js +37 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/capture-side-channel.js +89 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/captures.js +1975 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/constraint-extractor.js +311 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/constraint-filter.js +210 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/conversion-rank.js +163 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/file-local-linkage.js +327 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/header-scan.js +53 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/import-decomposer.js +134 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/import-target.js +16 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/index.js +33 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/inline-namespaces.js +379 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/interpret.js +239 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/member-lookup.js +470 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/merge-bindings.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/query.js +763 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/range-bindings.js +230 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/scope-resolver.js +354 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/simple-hooks.js +67 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/two-phase-lookup.js +348 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/type-classifier.js +56 -0
- package/dist/core/code/engine/core/ingestion/languages/cpp/user-defined-conversions.js +128 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/accessor-unwrap.js +67 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/arity-metadata.js +49 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/arity.js +40 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/cache-stats.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/captures.js +557 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/import-decomposer.js +96 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/import-target.js +176 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/index.js +95 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/interpret.js +150 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/merge-bindings.js +58 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/namespace-siblings.js +708 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/qualified-type-names.js +62 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/query.js +578 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/receiver-binding.js +142 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/resolution-config.js +18 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/scope-resolver.js +84 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp/simple-hooks.js +81 -0
- package/dist/core/code/engine/core/ingestion/languages/csharp.js +204 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/arity-metadata.js +38 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/arity.js +34 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/built-ins.js +37 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/cache-stats.js +30 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/captures.js +1096 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/expand-wildcards.js +34 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/extension-type-preprocess.js +33 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/import-target.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/index.js +45 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/interpret.js +101 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/merge-bindings.js +42 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/query.js +246 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/receiver-binding.js +90 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/scope-resolver.js +197 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/signature-bindings.js +54 -0
- package/dist/core/code/engine/core/ingestion/languages/dart/simple-hooks.js +61 -0
- package/dist/core/code/engine/core/ingestion/languages/dart.js +138 -0
- package/dist/core/code/engine/core/ingestion/languages/go/arity-metadata.js +71 -0
- package/dist/core/code/engine/core/ingestion/languages/go/arity.js +17 -0
- package/dist/core/code/engine/core/ingestion/languages/go/cache-stats.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/go/captures.js +492 -0
- package/dist/core/code/engine/core/ingestion/languages/go/expand-wildcards.js +97 -0
- package/dist/core/code/engine/core/ingestion/languages/go/generic-type-parameters.js +146 -0
- package/dist/core/code/engine/core/ingestion/languages/go/import-decomposer.js +47 -0
- package/dist/core/code/engine/core/ingestion/languages/go/import-target.js +70 -0
- package/dist/core/code/engine/core/ingestion/languages/go/index.js +39 -0
- package/dist/core/code/engine/core/ingestion/languages/go/interface-impls.js +955 -0
- package/dist/core/code/engine/core/ingestion/languages/go/interpret.js +177 -0
- package/dist/core/code/engine/core/ingestion/languages/go/merge-bindings.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/go/method-owners.js +131 -0
- package/dist/core/code/engine/core/ingestion/languages/go/namespace-mirror.js +56 -0
- package/dist/core/code/engine/core/ingestion/languages/go/package-clause.js +79 -0
- package/dist/core/code/engine/core/ingestion/languages/go/package-siblings.js +83 -0
- package/dist/core/code/engine/core/ingestion/languages/go/query.js +298 -0
- package/dist/core/code/engine/core/ingestion/languages/go/range-binding.js +127 -0
- package/dist/core/code/engine/core/ingestion/languages/go/receiver-binding.js +24 -0
- package/dist/core/code/engine/core/ingestion/languages/go/scope-resolver.js +75 -0
- package/dist/core/code/engine/core/ingestion/languages/go/simple-hooks.js +31 -0
- package/dist/core/code/engine/core/ingestion/languages/go/type-binding.js +279 -0
- package/dist/core/code/engine/core/ingestion/languages/go.js +160 -0
- package/dist/core/code/engine/core/ingestion/languages/index.js +66 -0
- package/dist/core/code/engine/core/ingestion/languages/java/analysis-features.js +16 -0
- package/dist/core/code/engine/core/ingestion/languages/java/arity-metadata.js +43 -0
- package/dist/core/code/engine/core/ingestion/languages/java/arity.js +27 -0
- package/dist/core/code/engine/core/ingestion/languages/java/cache-stats.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/java/capture-side-channel.js +123 -0
- package/dist/core/code/engine/core/ingestion/languages/java/captures.js +791 -0
- package/dist/core/code/engine/core/ingestion/languages/java/import-decomposer.js +88 -0
- package/dist/core/code/engine/core/ingestion/languages/java/import-target.js +103 -0
- package/dist/core/code/engine/core/ingestion/languages/java/index.js +43 -0
- package/dist/core/code/engine/core/ingestion/languages/java/interpret.js +146 -0
- package/dist/core/code/engine/core/ingestion/languages/java/merge-bindings.js +43 -0
- package/dist/core/code/engine/core/ingestion/languages/java/package-facts.js +16 -0
- package/dist/core/code/engine/core/ingestion/languages/java/package-siblings.js +11 -0
- package/dist/core/code/engine/core/ingestion/languages/java/query.js +319 -0
- package/dist/core/code/engine/core/ingestion/languages/java/receiver-binding.js +98 -0
- package/dist/core/code/engine/core/ingestion/languages/java/scope-resolver.js +213 -0
- package/dist/core/code/engine/core/ingestion/languages/java/simple-hooks.js +39 -0
- package/dist/core/code/engine/core/ingestion/languages/java/spring-aop.js +53 -0
- package/dist/core/code/engine/core/ingestion/languages/java/spring-bean-metadata.js +11 -0
- package/dist/core/code/engine/core/ingestion/languages/java/spring-conditionals.js +52 -0
- package/dist/core/code/engine/core/ingestion/languages/java/spring-config-bindings.js +222 -0
- package/dist/core/code/engine/core/ingestion/languages/java/spring-di.js +165 -0
- package/dist/core/code/engine/core/ingestion/languages/java.js +192 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/arity.js +15 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/captures.js +1122 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/import-target.js +56 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/index.js +109 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/interpret.js +45 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/merge-bindings.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/query.js +659 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/scope-resolver.js +78 -0
- package/dist/core/code/engine/core/ingestion/languages/javascript/simple-hooks.js +44 -0
- package/dist/core/code/engine/core/ingestion/languages/jvm/package-facts.js +46 -0
- package/dist/core/code/engine/core/ingestion/languages/jvm/package-siblings.js +200 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/arity-metadata.js +23 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/arity.js +18 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/cache-stats.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/capture-side-channel.js +160 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/captures.js +1262 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/companion-scopes.js +72 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/import-decomposer.js +40 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/import-target.js +135 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/index.js +26 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/interpret.js +75 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/merge-bindings.js +28 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/owners.js +134 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/package-facts.js +16 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/package-siblings.js +11 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/query.js +243 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/receiver-binding.js +103 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/scope-resolver.js +207 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/simple-hooks.js +42 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/spring-aop.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/spring-bean-metadata.js +11 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/spring-conditionals.js +53 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin/spring-di.js +304 -0
- package/dist/core/code/engine/core/ingestion/languages/kotlin.js +189 -0
- package/dist/core/code/engine/core/ingestion/languages/php/arity-metadata.js +66 -0
- package/dist/core/code/engine/core/ingestion/languages/php/arity.js +43 -0
- package/dist/core/code/engine/core/ingestion/languages/php/cache-stats.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/php/captures.js +1166 -0
- package/dist/core/code/engine/core/ingestion/languages/php/import-decomposer.js +238 -0
- package/dist/core/code/engine/core/ingestion/languages/php/import-target.js +213 -0
- package/dist/core/code/engine/core/ingestion/languages/php/index.js +85 -0
- package/dist/core/code/engine/core/ingestion/languages/php/interpret.js +256 -0
- package/dist/core/code/engine/core/ingestion/languages/php/merge-bindings.js +50 -0
- package/dist/core/code/engine/core/ingestion/languages/php/namespace-siblings.js +353 -0
- package/dist/core/code/engine/core/ingestion/languages/php/query.js +391 -0
- package/dist/core/code/engine/core/ingestion/languages/php/receiver-binding.js +135 -0
- package/dist/core/code/engine/core/ingestion/languages/php/scope-resolver.js +361 -0
- package/dist/core/code/engine/core/ingestion/languages/php/simple-hooks.js +116 -0
- package/dist/core/code/engine/core/ingestion/languages/php.js +302 -0
- package/dist/core/code/engine/core/ingestion/languages/python/arity-metadata.js +49 -0
- package/dist/core/code/engine/core/ingestion/languages/python/arity.js +41 -0
- package/dist/core/code/engine/core/ingestion/languages/python/cache-stats.js +34 -0
- package/dist/core/code/engine/core/ingestion/languages/python/captures.js +299 -0
- package/dist/core/code/engine/core/ingestion/languages/python/depends-references.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/python/import-decomposer.js +115 -0
- package/dist/core/code/engine/core/ingestion/languages/python/import-target.js +440 -0
- package/dist/core/code/engine/core/ingestion/languages/python/index-stats.js +30 -0
- package/dist/core/code/engine/core/ingestion/languages/python/index.js +96 -0
- package/dist/core/code/engine/core/ingestion/languages/python/interpret.js +430 -0
- package/dist/core/code/engine/core/ingestion/languages/python/merge-bindings.js +47 -0
- package/dist/core/code/engine/core/ingestion/languages/python/query.js +323 -0
- package/dist/core/code/engine/core/ingestion/languages/python/receiver-binding.js +310 -0
- package/dist/core/code/engine/core/ingestion/languages/python/scope-resolver.js +80 -0
- package/dist/core/code/engine/core/ingestion/languages/python/simple-hooks.js +53 -0
- package/dist/core/code/engine/core/ingestion/languages/python.js +140 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/arity.js +41 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/cache-stats.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/captures.js +864 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/import-target.js +88 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/index.js +29 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/interpret.js +115 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/merge-bindings.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/query.js +349 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/receiver-binding.js +70 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/scope-resolver.js +263 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby/simple-hooks.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/ruby.js +215 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/arity.js +16 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/cache-stats.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/captures.js +304 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/import-decomposer.js +167 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/import-target.js +108 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/index.js +29 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/interpret.js +201 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/merge-bindings.js +21 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/method-owners.js +76 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/module-path.js +222 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/qualified-call.js +482 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/query.js +280 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/range-binding.js +687 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/receiver-binding.js +148 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/scope-resolver.js +151 -0
- package/dist/core/code/engine/core/ingestion/languages/rust/simple-hooks.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/rust.js +183 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/arity-metadata.js +44 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/arity.js +45 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/base-type.js +30 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/cache-stats.js +32 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/captures.js +594 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/conditional-directive-preprocess.js +256 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/implicit-imports.js +60 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/import-decomposer.js +87 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/import-target.js +84 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/index.js +56 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/interpret.js +93 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/merge-bindings.js +51 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/query.js +226 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/receiver-binding.js +169 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/scope-resolver.js +192 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/sibling-type-bindings.js +68 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/signature-bindings.js +69 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/simple-hooks.js +65 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/target-grouping.js +97 -0
- package/dist/core/code/engine/core/ingestion/languages/swift/target-siblings.js +74 -0
- package/dist/core/code/engine/core/ingestion/languages/swift.js +246 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/arity-metadata.js +106 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/arity.js +57 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/array-callback.js +58 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/cache-stats.js +34 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/captures.js +956 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/cjs-export-assignment.js +535 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/cjs-module-exports.js +196 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/import-decomposer.js +374 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/import-target.js +65 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/index.js +108 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/interpret.js +344 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/merge-bindings.js +161 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/nuxt-auto-imports.js +325 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/query.js +1328 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/receiver-binding.js +201 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/scope-resolver.js +293 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript/simple-hooks.js +139 -0
- package/dist/core/code/engine/core/ingestion/languages/typescript.js +455 -0
- package/dist/core/code/engine/core/ingestion/languages/vue/captures.js +70 -0
- package/dist/core/code/engine/core/ingestion/languages/vue/import-target.js +61 -0
- package/dist/core/code/engine/core/ingestion/languages/vue/index.js +55 -0
- package/dist/core/code/engine/core/ingestion/languages/vue/scope-resolver.js +295 -0
- package/dist/core/code/engine/core/ingestion/languages/vue.js +96 -0
- package/dist/core/code/engine/core/ingestion/local-symbol-pruner.js +68 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/c-cpp.js +387 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/csharp.js +290 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/dart.js +392 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/go.js +179 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/jvm.js +350 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/php.js +306 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/python.js +312 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/ruby.js +289 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/rust.js +198 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/swift.js +286 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/configs/typescript-javascript.js +341 -0
- package/dist/core/code/engine/core/ingestion/method-extractors/generic.js +209 -0
- package/dist/core/code/engine/core/ingestion/method-types.js +3 -0
- package/dist/core/code/engine/core/ingestion/model/field-registry.js +41 -0
- package/dist/core/code/engine/core/ingestion/model/index.js +52 -0
- package/dist/core/code/engine/core/ingestion/model/method-registry.js +138 -0
- package/dist/core/code/engine/core/ingestion/model/owned-members-lookup.js +46 -0
- package/dist/core/code/engine/core/ingestion/model/registration-table.js +234 -0
- package/dist/core/code/engine/core/ingestion/model/resolve.js +183 -0
- package/dist/core/code/engine/core/ingestion/model/scope-resolution-indexes.js +43 -0
- package/dist/core/code/engine/core/ingestion/model/semantic-model.js +179 -0
- package/dist/core/code/engine/core/ingestion/model/symbol-table.js +216 -0
- package/dist/core/code/engine/core/ingestion/model/type-registry.js +84 -0
- package/dist/core/code/engine/core/ingestion/mro-processor.js +709 -0
- package/dist/core/code/engine/core/ingestion/parsing-processor.js +312 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/communities.js +69 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/cross-file.js +71 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/di.js +338 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/http-api-calls.js +312 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/index.js +54 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/mro.js +40 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/orm.js +78 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/parse-impl.js +1286 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/parse.js +41 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/processes.js +193 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/prune-local-symbols.js +29 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/registry.js +52 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/routes.js +409 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/rpc-edges.js +301 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/runner.js +207 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/scan.js +49 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/spring-aop.js +442 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/spring-auto-configuration.js +264 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/spring-config.js +440 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/structure.js +38 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/tools.js +89 -0
- package/dist/core/code/engine/core/ingestion/pipeline-phases/types.js +40 -0
- package/dist/core/code/engine/core/ingestion/pipeline.js +152 -0
- package/dist/core/code/engine/core/ingestion/process-processor.js +325 -0
- package/dist/core/code/engine/core/ingestion/resolve-references.js +205 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/constant-resolver.js +135 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/django-root-discovery.js +221 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/django.js +428 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/expo.js +39 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/fastapi-router-bindings.js +264 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/laravel.js +501 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/middleware.js +175 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/nextjs.js +81 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/php.js +25 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/python-const-resolver.js +307 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/response-shapes.js +299 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/route-path.js +71 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/spring-shared.js +310 -0
- package/dist/core/code/engine/core/ingestion/route-extractors/spring.js +441 -0
- package/dist/core/code/engine/core/ingestion/scope-extractor-bridge.js +60 -0
- package/dist/core/code/engine/core/ingestion/scope-extractor.js +1373 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/contract/scope-resolver.js +282 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/callee-id-sink.js +72 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/edges.js +194 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/ids.js +472 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/imports-to-edges.js +49 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/method-dispatch.js +43 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/node-lookup.js +274 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/graph-bridge/references-to-edges.js +93 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/callable-value-flow.js +1240 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/compound-receiver.js +1174 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/free-call-fallback.js +873 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/imported-return-types.js +226 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/mro.js +107 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/overload-narrowing.js +441 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/property-dispatch.js +122 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/passes/receiver-bound-calls.js +1720 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/pipeline/phase.js +395 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/pipeline/reconcile-ownership.js +208 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/pipeline/registry.js +49 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/pipeline/run.js +632 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/pipeline/validate-bindings-immutability.js +112 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/resolution-outcome.js +41 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/scope/namespace-targets.js +81 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/scope/walkers.js +1835 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/unresolved-receivers.js +242 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/utils/definition-id.js +22 -0
- package/dist/core/code/engine/core/ingestion/scope-resolution/workspace-index.js +151 -0
- package/dist/core/code/engine/core/ingestion/structure-processor.js +40 -0
- package/dist/core/code/engine/core/ingestion/tree-sitter-queries.js +2244 -0
- package/dist/core/code/engine/core/ingestion/ts-js-hoc-utils.js +115 -0
- package/dist/core/code/engine/core/ingestion/type-env.js +1136 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/c-cpp.js +555 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/csharp.js +570 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/dart.js +372 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/go.js +508 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/jvm.js +875 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/php.js +537 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/python.js +477 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/ruby.js +380 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/rust.js +502 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/shared.js +843 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/swift.js +490 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/types.js +2 -0
- package/dist/core/code/engine/core/ingestion/type-extractors/typescript.js +690 -0
- package/dist/core/code/engine/core/ingestion/utils/ast-helpers.js +1693 -0
- package/dist/core/code/engine/core/ingestion/utils/call-analysis.js +779 -0
- package/dist/core/code/engine/core/ingestion/utils/callable-flow-captures.js +932 -0
- package/dist/core/code/engine/core/ingestion/utils/callable-labels.js +49 -0
- package/dist/core/code/engine/core/ingestion/utils/deferred-resolution-profile.js +151 -0
- package/dist/core/code/engine/core/ingestion/utils/effective-ram.js +67 -0
- package/dist/core/code/engine/core/ingestion/utils/env.js +60 -0
- package/dist/core/code/engine/core/ingestion/utils/event-loop.js +9 -0
- package/dist/core/code/engine/core/ingestion/utils/graph-sort.js +103 -0
- package/dist/core/code/engine/core/ingestion/utils/heap-probe.js +45 -0
- package/dist/core/code/engine/core/ingestion/utils/heritage-marker.js +47 -0
- package/dist/core/code/engine/core/ingestion/utils/line-base.js +24 -0
- package/dist/core/code/engine/core/ingestion/utils/max-file-size.js +59 -0
- package/dist/core/code/engine/core/ingestion/utils/method-props.js +198 -0
- package/dist/core/code/engine/core/ingestion/utils/qualified-name.js +73 -0
- package/dist/core/code/engine/core/ingestion/utils/receiver-chain-captures.js +60 -0
- package/dist/core/code/engine/core/ingestion/utils/receiver-chain-codec.js +188 -0
- package/dist/core/code/engine/core/ingestion/utils/scope-tree-walk.js +36 -0
- package/dist/core/code/engine/core/ingestion/utils/symbol-labels.js +48 -0
- package/dist/core/code/engine/core/ingestion/utils/template-arguments.js +187 -0
- package/dist/core/code/engine/core/ingestion/utils/type-parameters.js +209 -0
- package/dist/core/code/engine/core/ingestion/utils/verbose.js +6 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/c-cpp.js +133 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/csharp.js +66 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/dart.js +111 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/go.js +153 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/jvm.js +145 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/php.js +61 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/python.js +104 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/ruby.js +55 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/rust.js +79 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/swift.js +91 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/configs/typescript-javascript.js +86 -0
- package/dist/core/code/engine/core/ingestion/variable-extractors/generic.js +111 -0
- package/dist/core/code/engine/core/ingestion/variable-types.js +3 -0
- package/dist/core/code/engine/core/ingestion/vue-sfc-extractor.js +544 -0
- package/dist/core/code/engine/core/ingestion/workers/callable-id.js +122 -0
- package/dist/core/code/engine/core/ingestion/workers/clone-safety.js +470 -0
- package/dist/core/code/engine/core/ingestion/workers/parse-worker.js +2456 -0
- package/dist/core/code/engine/core/ingestion/workers/post-result.js +90 -0
- package/dist/core/code/engine/core/ingestion/workers/quarantine.js +41 -0
- package/dist/core/code/engine/core/ingestion/workers/result-merge.js +59 -0
- package/dist/core/code/engine/core/ingestion/workers/worker-pool.js +1725 -0
- package/dist/core/code/engine/core/ingestion/workspace-config.js +139 -0
- package/dist/core/code/engine/core/lbug/conn-lock.js +72 -0
- package/dist/core/code/engine/core/lbug/csv-generator.js +710 -0
- package/dist/core/code/engine/core/lbug/cypher-escape.js +24 -0
- package/dist/core/code/engine/core/lbug/extension-load-error.js +339 -0
- package/dist/core/code/engine/core/lbug/extension-loader.js +261 -0
- package/dist/core/code/engine/core/lbug/graph-emit-sink.js +584 -0
- package/dist/core/code/engine/core/lbug/lbug-adapter.js +2703 -0
- package/dist/core/code/engine/core/lbug/lbug-config.js +1029 -0
- package/dist/core/code/engine/core/lbug/native-check.js +435 -0
- package/dist/core/code/engine/core/lbug/pool-adapter.js +973 -0
- package/dist/core/code/engine/core/lbug/query-params.js +25 -0
- package/dist/core/code/engine/core/lbug/query-result-utils.js +31 -0
- package/dist/core/code/engine/core/lbug/rel-pair-routing.js +373 -0
- package/dist/core/code/engine/core/lbug/schema.js +771 -0
- package/dist/core/code/engine/core/lbug/shutdown-helpers.js +40 -0
- package/dist/core/code/engine/core/lbug/sidecar-recovery.js +716 -0
- package/dist/core/code/engine/core/lbug/stdio-capture.js +49 -0
- package/dist/core/code/engine/core/lbug/sync-csv-writer.js +115 -0
- package/dist/core/code/engine/core/lbug/wal-checkpoint-driver.js +215 -0
- package/dist/core/code/engine/core/lbug/wal-driver-state.js +28 -0
- package/dist/core/code/engine/core/logger.js +339 -0
- package/dist/core/code/engine/core/platform/capabilities.js +91 -0
- package/dist/core/code/engine/core/run-analyze.js +1098 -0
- package/dist/core/code/engine/core/tree-sitter/parser-loader.js +281 -0
- package/dist/core/code/engine/core/tree-sitter/safe-parse.js +258 -0
- package/dist/core/code/engine/core/tree-sitter/vendored-grammars.js +64 -0
- package/dist/core/code/engine/lib/utils.js +121 -0
- package/dist/core/code/engine/mcp/core/lbug-adapter.js +27 -0
- package/dist/core/code/engine/mcp/local/aop-metadata.js +230 -0
- package/dist/core/code/engine/mcp/local/bean-metadata.js +49 -0
- package/dist/core/code/engine/mcp/local/limits.js +15 -0
- package/dist/core/code/engine/mcp/local/line-display.js +6 -0
- package/dist/core/code/engine/mcp/local/local-backend.js +4142 -0
- package/dist/core/code/engine/storage/branch-index.js +72 -0
- package/dist/core/code/engine/storage/file-hash.js +95 -0
- package/dist/core/code/engine/storage/fs-atomic.js +34 -0
- package/dist/core/code/engine/storage/git.js +555 -0
- package/dist/core/code/engine/storage/index-lock.js +664 -0
- package/dist/core/code/engine/storage/parse-cache.js +650 -0
- package/dist/core/code/engine/storage/parsedfile-store.js +620 -0
- package/dist/core/code/engine/storage/repo-manager.js +1061 -0
- package/dist/core/code/engine/storage/scope-index-store.js +247 -0
- package/dist/core/code/engine/types/pipeline.js +2 -0
- package/dist/core/code/scripts/install-duckdb-extension.mjs +125 -0
- package/dist/core/code/scripts/resolve-analyze-cmd.cjs +346 -0
- package/dist/core/code/shared/graph/types.js +8 -0
- package/dist/core/code/shared/index.js +105 -0
- package/dist/core/code/shared/integrations/circuit-breaker.js +242 -0
- package/dist/core/code/shared/integrations/resilient-fetch.js +224 -0
- package/dist/core/code/shared/integrations/retry.js +70 -0
- package/dist/core/code/shared/integrations/understand-quickly.js +145 -0
- package/dist/core/code/shared/language-detection.js +162 -0
- package/dist/core/code/shared/languages.js +27 -0
- package/dist/core/code/shared/lbug/schema-constants.js +98 -0
- package/dist/core/code/shared/mro-strategy.js +2 -0
- package/dist/core/code/shared/pipeline.js +5 -0
- package/dist/core/code/shared/scope-resolution/callable-flow-site.js +11 -0
- package/dist/core/code/shared/scope-resolution/def-index.js +53 -0
- package/dist/core/code/shared/scope-resolution/evidence-weights.js +87 -0
- package/dist/core/code/shared/scope-resolution/finalize-algorithm.js +807 -0
- package/dist/core/code/shared/scope-resolution/language-classification.js +46 -0
- package/dist/core/code/shared/scope-resolution/method-dispatch-index.js +100 -0
- package/dist/core/code/shared/scope-resolution/module-scope-index.js +59 -0
- package/dist/core/code/shared/scope-resolution/origin-priority.js +23 -0
- package/dist/core/code/shared/scope-resolution/parsed-file.js +54 -0
- package/dist/core/code/shared/scope-resolution/position-index.js +136 -0
- package/dist/core/code/shared/scope-resolution/qualified-name-index.js +77 -0
- package/dist/core/code/shared/scope-resolution/reference-site.js +24 -0
- package/dist/core/code/shared/scope-resolution/registries/class-registry.js +32 -0
- package/dist/core/code/shared/scope-resolution/registries/context.js +52 -0
- package/dist/core/code/shared/scope-resolution/registries/evidence.js +152 -0
- package/dist/core/code/shared/scope-resolution/registries/field-registry.js +33 -0
- package/dist/core/code/shared/scope-resolution/registries/lookup-core.js +392 -0
- package/dist/core/code/shared/scope-resolution/registries/lookup-qualified.js +58 -0
- package/dist/core/code/shared/scope-resolution/registries/macro-registry.js +34 -0
- package/dist/core/code/shared/scope-resolution/registries/method-registry.js +34 -0
- package/dist/core/code/shared/scope-resolution/registries/tie-breaks.js +63 -0
- package/dist/core/code/shared/scope-resolution/resolve-type-ref.js +128 -0
- package/dist/core/code/shared/scope-resolution/scope-id.js +49 -0
- package/dist/core/code/shared/scope-resolution/scope-tree.js +225 -0
- package/dist/core/code/shared/scope-resolution/symbol-definition.js +12 -0
- package/dist/core/code/shared/scope-resolution/types.js +25 -0
- package/dist/core/code/shared/test-helpers.js +17 -0
- package/dist/core/code/vendor/leiden/index.cjs +355 -0
- package/dist/core/code/vendor/leiden/utils.cjs +419 -0
- package/dist/core/features/scanner.d.ts +2 -0
- package/dist/core/features/scanner.d.ts.map +1 -1
- package/dist/core/features/scanner.js +27 -6
- package/dist/core/features/scanner.js.map +1 -1
- package/dist/core/timeline/cli.d.ts.map +1 -1
- package/dist/core/timeline/cli.js +13 -6
- package/dist/core/timeline/cli.js.map +1 -1
- package/dist/core/timeline/debris.d.ts +20 -0
- package/dist/core/timeline/debris.d.ts.map +1 -0
- package/dist/core/timeline/debris.js +124 -0
- package/dist/core/timeline/debris.js.map +1 -0
- package/dist/core/timeline/hook-runner.d.ts.map +1 -1
- package/dist/core/timeline/hook-runner.js +3 -1
- package/dist/core/timeline/hook-runner.js.map +1 -1
- package/dist/core/timeline/hooks.d.ts.map +1 -1
- package/dist/core/timeline/hooks.js +13 -5
- package/dist/core/timeline/hooks.js.map +1 -1
- package/dist/core/timeline/installer.d.ts +2 -0
- package/dist/core/timeline/installer.d.ts.map +1 -1
- package/dist/core/timeline/installer.js +12 -0
- package/dist/core/timeline/installer.js.map +1 -1
- package/dist/core/timeline/project-root.d.ts +21 -0
- package/dist/core/timeline/project-root.d.ts.map +1 -0
- package/dist/core/timeline/project-root.js +83 -0
- package/dist/core/timeline/project-root.js.map +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Swift same-module return-type typeBinding mirroring for the
|
|
4
|
+
* `mirrorNamespaceTypeBindings` hook.
|
|
5
|
+
*
|
|
6
|
+
* Swift gives every file in a module (an SPM target) visibility of every
|
|
7
|
+
* sibling's top-level declarations without a syntactic `import`. For a
|
|
8
|
+
* chained call like
|
|
9
|
+
*
|
|
10
|
+
* App.swift: let user = getUser(); user.save() // user → getUser → ?
|
|
11
|
+
* Models.swift: func getUser() -> User { … } // getUser → User
|
|
12
|
+
*
|
|
13
|
+
* to resolve `user.save()` cross-file, App.swift's scope chain must be
|
|
14
|
+
* able to follow `getUser → User`. The function return-type binding
|
|
15
|
+
* (`getUser → User`) lives on Models.swift's module scope, so we mirror
|
|
16
|
+
* sibling module-scope typeBindings into the importer's module scope —
|
|
17
|
+
* the same trick Go uses (`mirrorGoNamespaceTypeBindings`), but Swift has
|
|
18
|
+
* no namespace-import edges, so module membership is the SPM target
|
|
19
|
+
* subtree (`Sources/<Target>/…`): threaded in via the SPM target map
|
|
20
|
+
* (`resolutionConfig` → `coerceSwiftTargets`) and grouped by
|
|
21
|
+
* `groupSwiftFilesBySpmTarget` (replicating legacy `groupSwiftFilesByTarget`;
|
|
22
|
+
* no-source-dir → all files form one `__default__` module).
|
|
23
|
+
*
|
|
24
|
+
* Runs after `populateNamespaceSiblings` and before
|
|
25
|
+
* `propagateImportedReturnTypes`, so the SCC-ordered propagation pass
|
|
26
|
+
* sees the mirrored bindings and chains `user → getUser → User` to the
|
|
27
|
+
* terminal class. Each mirrored binding is chain-followed inside its
|
|
28
|
+
* source module first so we mirror the terminal type, not an intermediate
|
|
29
|
+
* intra-module reference. `Scope.typeBindings` is mutated via the
|
|
30
|
+
* sanctioned non-frozen Map cast (Contract Invariant I6).
|
|
31
|
+
*/
|
|
32
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
33
|
+
exports.mirrorSwiftSiblingTypeBindings = mirrorSwiftSiblingTypeBindings;
|
|
34
|
+
const imported_return_types_js_1 = require("../../scope-resolution/passes/imported-return-types.js");
|
|
35
|
+
const target_grouping_js_1 = require("./target-grouping.js");
|
|
36
|
+
function mirrorSwiftSiblingTypeBindings(parsedFiles, indexes, workspaceIndex, resolutionConfig) {
|
|
37
|
+
const moduleScopeByFile = workspaceIndex.moduleScopeByFile;
|
|
38
|
+
// Group files by SPM target subtree (the module). No-source-dir → all
|
|
39
|
+
// files in one `__default__` bucket.
|
|
40
|
+
const targets = (0, target_grouping_js_1.coerceSwiftTargets)(resolutionConfig);
|
|
41
|
+
const filesByTarget = (0, target_grouping_js_1.groupSwiftFilesBySpmTarget)(parsedFiles, (parsed) => parsed.filePath, targets);
|
|
42
|
+
for (const [, group] of filesByTarget) {
|
|
43
|
+
if (group.length < 2)
|
|
44
|
+
continue; // no siblings to mirror from
|
|
45
|
+
const files = group.map((parsed) => parsed.filePath);
|
|
46
|
+
for (const importerFile of files) {
|
|
47
|
+
const importerModule = moduleScopeByFile.get(importerFile);
|
|
48
|
+
if (importerModule === undefined)
|
|
49
|
+
continue;
|
|
50
|
+
for (const sourceFile of files) {
|
|
51
|
+
if (sourceFile === importerFile)
|
|
52
|
+
continue;
|
|
53
|
+
const sourceModule = moduleScopeByFile.get(sourceFile);
|
|
54
|
+
if (sourceModule === undefined)
|
|
55
|
+
continue;
|
|
56
|
+
for (const [name, ref] of sourceModule.typeBindings) {
|
|
57
|
+
if (name.length === 0)
|
|
58
|
+
continue;
|
|
59
|
+
// A local annotation on the importer must win over a sibling's.
|
|
60
|
+
if (importerModule.typeBindings.has(name))
|
|
61
|
+
continue;
|
|
62
|
+
const terminal = (0, imported_return_types_js_1.followChainPostFinalize)(ref, sourceModule.id, indexes);
|
|
63
|
+
importerModule.typeBindings.set(name, terminal);
|
|
64
|
+
}
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Synthesize parameter-type and function return-type `@type-binding.*`
|
|
4
|
+
* captures for a Swift function-like node.
|
|
5
|
+
*
|
|
6
|
+
* Why synthesized rather than queried: Swift's tree-sitter grammar reuses
|
|
7
|
+
* the field name `name:` for the function name, each parameter's label,
|
|
8
|
+
* each parameter's type, AND the function's return type. A tree-sitter
|
|
9
|
+
* query with two `name:` fields cross-assigns those captures and produces
|
|
10
|
+
* garbage bindings (e.g. `save: save`). Reading the node via the existing
|
|
11
|
+
* `swiftMethodConfig.extractParameters` / `extractReturnType` extractors
|
|
12
|
+
* — which already handle the grammar correctly for the legacy parse path
|
|
13
|
+
* — yields the right name→type pairs. This mirrors how receiver and arity
|
|
14
|
+
* metadata are synthesized in `captures.ts` instead of queried.
|
|
15
|
+
*
|
|
16
|
+
* - **Parameter bindings** anchor inside the function body so the
|
|
17
|
+
* binding lands in the Function scope: `func f(u: User) { u.save() }`
|
|
18
|
+
* → `u: User` visible in f's body.
|
|
19
|
+
* - **Return-type binding** anchors at the function node and carries
|
|
20
|
+
* `@type-binding.return`, which `swiftBindingScopeFor` hoists to the
|
|
21
|
+
* Module scope so `propagateImportedReturnTypes` mirrors it across
|
|
22
|
+
* files and callers see `let u = getUser(); u.save()`.
|
|
23
|
+
*/
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.synthesizeSwiftSignatureBindings = synthesizeSwiftSignatureBindings;
|
|
26
|
+
const ast_helpers_js_1 = require("../../utils/ast-helpers.js");
|
|
27
|
+
const swift_js_1 = require("../../method-extractors/configs/swift.js");
|
|
28
|
+
const NAMED_FUNCTION_NODE_TYPES = new Set([
|
|
29
|
+
'function_declaration',
|
|
30
|
+
'protocol_function_declaration',
|
|
31
|
+
]);
|
|
32
|
+
function synthesizeSwiftSignatureBindings(fnNode) {
|
|
33
|
+
const out = [];
|
|
34
|
+
// ── Parameter bindings (anchor in the body for Function-scope landing) ──
|
|
35
|
+
const params = swift_js_1.swiftMethodConfig.extractParameters?.(fnNode) ?? [];
|
|
36
|
+
if (params.length > 0) {
|
|
37
|
+
const bodyNode = fnNode.childForFieldName('body');
|
|
38
|
+
// Anchor params inside the body when present; for bodyless protocol
|
|
39
|
+
// requirements there is no Function scope to bind locals into, so skip.
|
|
40
|
+
if (bodyNode !== null) {
|
|
41
|
+
for (const p of params) {
|
|
42
|
+
if (p.type === null || p.name === '')
|
|
43
|
+
continue;
|
|
44
|
+
out.push(buildBindingMatch(bodyNode, '@type-binding.parameter', p.name, p.type));
|
|
45
|
+
}
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
// ── Return-type binding (function name → return type, hoisted to Module) ──
|
|
49
|
+
// Only named functions have a name to bind; init/deinit have no return.
|
|
50
|
+
if (NAMED_FUNCTION_NODE_TYPES.has(fnNode.type)) {
|
|
51
|
+
const funcName = swift_js_1.swiftMethodConfig.extractName?.(fnNode);
|
|
52
|
+
const returnType = swift_js_1.swiftMethodConfig.extractReturnType?.(fnNode);
|
|
53
|
+
if (funcName !== undefined &&
|
|
54
|
+
funcName !== '' &&
|
|
55
|
+
returnType !== undefined &&
|
|
56
|
+
returnType !== '') {
|
|
57
|
+
out.push(buildBindingMatch(fnNode, '@type-binding.return', funcName, returnType));
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
return out;
|
|
61
|
+
}
|
|
62
|
+
function buildBindingMatch(anchorNode, sourceTag, name, typeText) {
|
|
63
|
+
const m = {
|
|
64
|
+
[sourceTag]: (0, ast_helpers_js_1.nodeToCapture)(sourceTag, anchorNode),
|
|
65
|
+
'@type-binding.name': (0, ast_helpers_js_1.syntheticCapture)('@type-binding.name', anchorNode, name),
|
|
66
|
+
'@type-binding.type': (0, ast_helpers_js_1.syntheticCapture)('@type-binding.type', anchorNode, typeText),
|
|
67
|
+
};
|
|
68
|
+
return m;
|
|
69
|
+
}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Trivial / no-op-ish hooks for the Swift provider. Kept together
|
|
4
|
+
* because each is a few lines and they share a theme: they make the
|
|
5
|
+
* provider's choice explicit rather than relying on "absence == default"
|
|
6
|
+
* so reviewers don't have to re-derive the analysis.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.swiftBindingScopeFor = swiftBindingScopeFor;
|
|
10
|
+
exports.swiftImportOwningScope = swiftImportOwningScope;
|
|
11
|
+
exports.swiftReceiverBinding = swiftReceiverBinding;
|
|
12
|
+
// ─── bindingScopeFor ──────────────────────────────────────────────────────
|
|
13
|
+
/** Swift uses the central extractor's "innermost enclosing scope" default
|
|
14
|
+
* for most declarations: class-body declarations attach to the Class
|
|
15
|
+
* scope, function-body locals to the Function scope.
|
|
16
|
+
*
|
|
17
|
+
* Exception: **function return-type bindings** (`@type-binding.return`)
|
|
18
|
+
* must hoist to the Module scope. The default auto-hoist promotes only
|
|
19
|
+
* one level (Function → its parent). For top-level functions the parent
|
|
20
|
+
* is already the Module so the default works, but for methods declared
|
|
21
|
+
* inside a class/struct/extension the parent is the Class — the return
|
|
22
|
+
* binding would get stuck there, invisible to:
|
|
23
|
+
* - chain-follow's parent-chain walk (`let u = getUser(); u.save()`);
|
|
24
|
+
* - cross-file `propagateImportedReturnTypes`, which reads only
|
|
25
|
+
* `sourceModule.typeBindings`.
|
|
26
|
+
* Walking to Module restores both. Mirrors `csharpBindingScopeFor`. */
|
|
27
|
+
function swiftBindingScopeFor(decl, innermost, tree) {
|
|
28
|
+
if (decl['@type-binding.return'] !== undefined) {
|
|
29
|
+
let cur = innermost;
|
|
30
|
+
while (cur !== undefined && cur.kind !== 'Module') {
|
|
31
|
+
const parentId = cur.parent ?? null;
|
|
32
|
+
if (parentId === null)
|
|
33
|
+
break;
|
|
34
|
+
cur = tree.getScope(parentId);
|
|
35
|
+
}
|
|
36
|
+
if (cur !== undefined && cur.kind === 'Module')
|
|
37
|
+
return cur.id;
|
|
38
|
+
}
|
|
39
|
+
return null;
|
|
40
|
+
}
|
|
41
|
+
// ─── importOwningScope ────────────────────────────────────────────────────
|
|
42
|
+
/** Swift imports only appear at file (module) scope and bring a whole
|
|
43
|
+
* module into view there. Attach the import to the Module scope; for any
|
|
44
|
+
* other innermost scope delegate to the default (returns null). */
|
|
45
|
+
function swiftImportOwningScope(_imp, innermost, _tree) {
|
|
46
|
+
if (innermost.kind === 'Module')
|
|
47
|
+
return innermost.id;
|
|
48
|
+
return null;
|
|
49
|
+
}
|
|
50
|
+
// ─── receiverBinding ──────────────────────────────────────────────────────
|
|
51
|
+
/** Look up `self` (or `super`) in the function scope's type bindings.
|
|
52
|
+
*
|
|
53
|
+
* `self` / `super` are synthesized as type bindings on instance methods
|
|
54
|
+
* during capture emission (`receiver-binding.ts`) — `self` for every
|
|
55
|
+
* method inside a class/struct/extension/protocol body, and `super`
|
|
56
|
+
* additionally for methods of a class with a declared superclass. This
|
|
57
|
+
* hook returns a non-null `TypeRef` for instance-method bodies.
|
|
58
|
+
*
|
|
59
|
+
* Returns `null` for static methods (no `self` synthesized), free
|
|
60
|
+
* functions (no enclosing type), and non-Function scopes. */
|
|
61
|
+
function swiftReceiverBinding(functionScope) {
|
|
62
|
+
if (functionScope.kind !== 'Function')
|
|
63
|
+
return null;
|
|
64
|
+
return functionScope.typeBindings.get('self') ?? functionScope.typeBindings.get('super') ?? null;
|
|
65
|
+
}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Swift SPM-target file grouping for the registry-primary same-module
|
|
4
|
+
* hooks (`implicit-imports.ts`, `target-siblings.ts`,
|
|
5
|
+
* `sibling-type-bindings.ts`).
|
|
6
|
+
*
|
|
7
|
+
* A Swift module is an SPM *target* — a directory *subtree*
|
|
8
|
+
* (`Sources/<Target>/…`), not a single immediate directory. Grouping by
|
|
9
|
+
* the immediate containing directory (the prior `containingDir` proxy)
|
|
10
|
+
* drops cross-directory same-module edges and can mis-resolve a
|
|
11
|
+
* constructor call to a wrong same-simple-named type in another target.
|
|
12
|
+
*
|
|
13
|
+
* This module duplicates the legacy `groupSwiftFilesByTarget`
|
|
14
|
+
* (`languages/swift.ts`) semantics **verbatim** so the registry-primary
|
|
15
|
+
* path matches legacy SPM-subtree grouping without touching the legacy
|
|
16
|
+
* pipeline (hard constraint: legacy stays byte-identical). The SPM target
|
|
17
|
+
* map is threaded in via the `resolutionConfig` channel
|
|
18
|
+
* (`loadSwiftPackageConfig` → `resolutionConfig` → these hooks); see
|
|
19
|
+
* `scope-resolver.ts` and `scope-resolution/pipeline/run.ts`.
|
|
20
|
+
*
|
|
21
|
+
* NOTE: This intentionally differs from the import-config module's
|
|
22
|
+
* leading-`startsWith` (`import-resolvers/configs/swift.ts`): that module
|
|
23
|
+
* fans a file out to EVERY matching target (a nested file can belong to
|
|
24
|
+
* multiple configured target dirs there), whereas legacy module grouping
|
|
25
|
+
* assigns each file to the FIRST matching target only (legacy `break`s) —
|
|
26
|
+
* one bucket per file. Do not copy the import-config behavior here.
|
|
27
|
+
*/
|
|
28
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
29
|
+
exports.groupSwiftFilesBySpmTarget = groupSwiftFilesBySpmTarget;
|
|
30
|
+
exports.coerceSwiftTargets = coerceSwiftTargets;
|
|
31
|
+
const DEFAULT_TARGET = '__default__';
|
|
32
|
+
/**
|
|
33
|
+
* Group `items` by SPM target subtree, replicating legacy
|
|
34
|
+
* `groupSwiftFilesByTarget` semantics exactly:
|
|
35
|
+
*
|
|
36
|
+
* - `targets` null/empty (no scanned source dir found) → ALL items go to
|
|
37
|
+
* a single `__default__` bucket (single-Xcode-project assumption).
|
|
38
|
+
* - Otherwise: a file matches a target when its normalized path either
|
|
39
|
+
* starts with `<targetDir>/` (`indexOf === 0`) OR contains it at a `/`
|
|
40
|
+
* boundary (`norm[idx - 1] === '/'`). Each file is assigned to the
|
|
41
|
+
* FIRST matching target only (one bucket per file, no fan-out).
|
|
42
|
+
* - Files matching no target fall into the `__default__` bucket.
|
|
43
|
+
*
|
|
44
|
+
* `targets` is `name → directory` (the `SwiftPackageConfig.targets` map).
|
|
45
|
+
*/
|
|
46
|
+
function groupSwiftFilesBySpmTarget(items, getPath, targets) {
|
|
47
|
+
// No SPM config -> single target (common for Xcode projects).
|
|
48
|
+
if (targets === null || targets.size === 0) {
|
|
49
|
+
return new Map([[DEFAULT_TARGET, [...items]]]);
|
|
50
|
+
}
|
|
51
|
+
// Pre-convert target dirs to normalized prefix format once.
|
|
52
|
+
const targetPrefixes = [...targets.entries()].map(([name, dir]) => ({
|
|
53
|
+
name,
|
|
54
|
+
prefix: dir.replace(/\\/g, '/') + '/',
|
|
55
|
+
}));
|
|
56
|
+
const groups = new Map();
|
|
57
|
+
const defaultGroup = [];
|
|
58
|
+
for (const item of items) {
|
|
59
|
+
const rawPath = getPath(item);
|
|
60
|
+
const normalized = rawPath.includes('\\') ? rawPath.replace(/\\/g, '/') : rawPath;
|
|
61
|
+
let assigned = false;
|
|
62
|
+
for (const { name, prefix } of targetPrefixes) {
|
|
63
|
+
const idx = normalized.indexOf(prefix);
|
|
64
|
+
if (idx === 0 || (idx > 0 && normalized[idx - 1] === '/')) {
|
|
65
|
+
let group = groups.get(name);
|
|
66
|
+
if (group === undefined) {
|
|
67
|
+
group = [];
|
|
68
|
+
groups.set(name, group);
|
|
69
|
+
}
|
|
70
|
+
group.push(item);
|
|
71
|
+
assigned = true;
|
|
72
|
+
break; // FIRST match only — one bucket per file, no fan-out.
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
if (!assigned)
|
|
76
|
+
defaultGroup.push(item);
|
|
77
|
+
}
|
|
78
|
+
if (defaultGroup.length > 0)
|
|
79
|
+
groups.set(DEFAULT_TARGET, defaultGroup);
|
|
80
|
+
return groups;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Duck-type the opaque `resolutionConfig` (loaded by
|
|
84
|
+
* `loadSwiftPackageConfig` and threaded through the orchestrator) into the
|
|
85
|
+
* SPM `targets` map, or `null` when no Swift package config is present.
|
|
86
|
+
*
|
|
87
|
+
* Uses structural duck-typing (no `instanceof`) because the value crosses
|
|
88
|
+
* the `unknown`-typed `resolutionConfig` channel and may be `null`,
|
|
89
|
+
* `undefined`, or a config object whose `targets` is a `Map<string,string>`.
|
|
90
|
+
*/
|
|
91
|
+
function coerceSwiftTargets(resolutionConfig) {
|
|
92
|
+
const config = resolutionConfig;
|
|
93
|
+
if (config != null && config.targets instanceof Map) {
|
|
94
|
+
return config.targets;
|
|
95
|
+
}
|
|
96
|
+
return null;
|
|
97
|
+
}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Swift same-module (SPM target) implicit visibility for the
|
|
4
|
+
* `populateNamespaceSiblings` hook.
|
|
5
|
+
*
|
|
6
|
+
* Swift gives every file in a module access to every other file's
|
|
7
|
+
* top-level declarations WITHOUT any `import` statement (whole-module
|
|
8
|
+
* visibility). This is the Swift analogue of Go's same-package sibling
|
|
9
|
+
* visibility — `populateGoPackageSiblings` is the template.
|
|
10
|
+
*
|
|
11
|
+
* Module identity: Swift has no in-source `package X` marker. The SPM
|
|
12
|
+
* target is a directory subtree (`Sources/<Target>/…`). Module membership
|
|
13
|
+
* is threaded in via the SPM target map (`ctx.resolutionConfig` →
|
|
14
|
+
* `coerceSwiftTargets`) and grouped by `groupSwiftFilesBySpmTarget`,
|
|
15
|
+
* replicating legacy `wireSwiftImplicitImports`'s `groupSwiftFilesByTarget`:
|
|
16
|
+
* files are grouped by SPM target subtree when a package config is present,
|
|
17
|
+
* else ALL Swift files form one module (`__default__`,
|
|
18
|
+
* single-Xcode-project assumption). Every `.swift` file in the same target
|
|
19
|
+
* sees its siblings' top-level defs.
|
|
20
|
+
*
|
|
21
|
+
* Bindings are added through the append-only `bindingAugmentations`
|
|
22
|
+
* channel (Contract Invariant I8) with `origin: 'namespace'`, exactly
|
|
23
|
+
* like the Go implementation — `indexes.bindings` is frozen post-
|
|
24
|
+
* finalize and must not be mutated.
|
|
25
|
+
*/
|
|
26
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
27
|
+
exports.populateSwiftTargetSiblings = populateSwiftTargetSiblings;
|
|
28
|
+
const target_grouping_js_1 = require("./target-grouping.js");
|
|
29
|
+
function populateSwiftTargetSiblings(parsedFiles, indexes, ctx) {
|
|
30
|
+
// Group files by SPM target subtree (the module). No-source-dir → all
|
|
31
|
+
// files in one `__default__` bucket.
|
|
32
|
+
const targets = (0, target_grouping_js_1.coerceSwiftTargets)(ctx.resolutionConfig);
|
|
33
|
+
const filesByTarget = (0, target_grouping_js_1.groupSwiftFilesBySpmTarget)(parsedFiles, (parsed) => parsed.filePath, targets);
|
|
34
|
+
const augmentations = indexes.bindingAugmentations;
|
|
35
|
+
for (const [, group] of filesByTarget) {
|
|
36
|
+
if (group.length < 2)
|
|
37
|
+
continue; // no siblings to share
|
|
38
|
+
const siblings = group.map((parsed) => ({
|
|
39
|
+
filePath: parsed.filePath,
|
|
40
|
+
defs: [...parsed.localDefs],
|
|
41
|
+
}));
|
|
42
|
+
for (const target of siblings) {
|
|
43
|
+
for (const receiver of siblings) {
|
|
44
|
+
if (receiver.filePath === target.filePath)
|
|
45
|
+
continue; // no self-reference
|
|
46
|
+
const receiverModule = indexes.moduleScopes.byFilePath.get(receiver.filePath);
|
|
47
|
+
if (receiverModule === undefined)
|
|
48
|
+
continue;
|
|
49
|
+
for (const def of target.defs) {
|
|
50
|
+
const name = def.qualifiedName?.split('.').pop() ?? def.qualifiedName ?? '';
|
|
51
|
+
if (name === '')
|
|
52
|
+
continue;
|
|
53
|
+
const bucket = getAugmentationBucket(augmentations, receiverModule, name);
|
|
54
|
+
if (bucket.some((b) => b.def.nodeId === def.nodeId))
|
|
55
|
+
continue;
|
|
56
|
+
bucket.push({ def, origin: 'namespace' });
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
function getAugmentationBucket(augmentations, scopeId, name) {
|
|
63
|
+
let scopeBindings = augmentations.get(scopeId);
|
|
64
|
+
if (scopeBindings === undefined) {
|
|
65
|
+
scopeBindings = new Map();
|
|
66
|
+
augmentations.set(scopeId, scopeBindings);
|
|
67
|
+
}
|
|
68
|
+
let bucketArr = scopeBindings.get(name);
|
|
69
|
+
if (bucketArr === undefined) {
|
|
70
|
+
bucketArr = [];
|
|
71
|
+
scopeBindings.set(name, bucketArr);
|
|
72
|
+
}
|
|
73
|
+
return bucketArr;
|
|
74
|
+
}
|
|
@@ -0,0 +1,246 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Swift Language Provider
|
|
4
|
+
*
|
|
5
|
+
* Assembles all Swift-specific ingestion capabilities into a single
|
|
6
|
+
* LanguageProvider, following the Strategy pattern used by the pipeline.
|
|
7
|
+
*/
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
exports.swiftProvider = void 0;
|
|
10
|
+
const index_js_1 = require("../../../../shared/index.js");
|
|
11
|
+
const generic_js_1 = require("../class-extractors/generic.js");
|
|
12
|
+
const swift_js_1 = require("../class-extractors/configs/swift.js");
|
|
13
|
+
const language_provider_js_1 = require("../language-provider.js");
|
|
14
|
+
const swift_js_2 = require("../type-extractors/swift.js");
|
|
15
|
+
const export_detection_js_1 = require("../export-detection.js");
|
|
16
|
+
const resolver_factory_js_1 = require("../import-resolvers/resolver-factory.js");
|
|
17
|
+
const swift_js_3 = require("../import-resolvers/configs/swift.js");
|
|
18
|
+
const tree_sitter_queries_js_1 = require("../tree-sitter-queries.js");
|
|
19
|
+
const ast_helpers_js_1 = require("../utils/ast-helpers.js");
|
|
20
|
+
const generic_js_2 = require("../field-extractors/generic.js");
|
|
21
|
+
const swift_js_4 = require("../field-extractors/configs/swift.js");
|
|
22
|
+
const generic_js_3 = require("../method-extractors/generic.js");
|
|
23
|
+
const swift_js_5 = require("../method-extractors/configs/swift.js");
|
|
24
|
+
const generic_js_4 = require("../variable-extractors/generic.js");
|
|
25
|
+
const swift_js_6 = require("../variable-extractors/configs/swift.js");
|
|
26
|
+
const generic_js_5 = require("../call-extractors/generic.js");
|
|
27
|
+
const swift_js_7 = require("../call-extractors/configs/swift.js");
|
|
28
|
+
const swift_js_8 = require("../cfg/visitors/swift.js");
|
|
29
|
+
const index_js_2 = require("./swift/index.js");
|
|
30
|
+
const conditional_directive_preprocess_js_1 = require("./swift/conditional-directive-preprocess.js");
|
|
31
|
+
/** Swift init/deinit declarations have special names and Constructor label. */
|
|
32
|
+
const swiftExtractFunctionName = (node) => {
|
|
33
|
+
if (node.type === 'init_declaration')
|
|
34
|
+
return { funcName: 'init', label: 'Constructor' };
|
|
35
|
+
if (node.type === 'deinit_declaration')
|
|
36
|
+
return { funcName: 'deinit', label: 'Constructor' };
|
|
37
|
+
return null; // fall through to generic
|
|
38
|
+
};
|
|
39
|
+
const orderSwiftSameNameTypeCandidates = ({ callSiteFilePath, candidates, }) => {
|
|
40
|
+
if (!callSiteFilePath.endsWith('.swift'))
|
|
41
|
+
return null;
|
|
42
|
+
if (candidates.length <= 1)
|
|
43
|
+
return null;
|
|
44
|
+
if (!candidates.every((c) => c.type === candidates[0].type))
|
|
45
|
+
return null;
|
|
46
|
+
if (candidates[0].type !== 'Class' && candidates[0].type !== 'Struct')
|
|
47
|
+
return null;
|
|
48
|
+
if (!candidates.every((c) => c.filePath.endsWith('.swift')))
|
|
49
|
+
return null;
|
|
50
|
+
return [...candidates].sort((a, b) => a.filePath.length - b.filePath.length || a.filePath.localeCompare(b.filePath));
|
|
51
|
+
};
|
|
52
|
+
const BUILT_INS = new Set([
|
|
53
|
+
'print',
|
|
54
|
+
'debugPrint',
|
|
55
|
+
'dump',
|
|
56
|
+
'fatalError',
|
|
57
|
+
'precondition',
|
|
58
|
+
'preconditionFailure',
|
|
59
|
+
'assert',
|
|
60
|
+
'assertionFailure',
|
|
61
|
+
'NSLog',
|
|
62
|
+
'abs',
|
|
63
|
+
'min',
|
|
64
|
+
'max',
|
|
65
|
+
'zip',
|
|
66
|
+
'stride',
|
|
67
|
+
'sequence',
|
|
68
|
+
'repeatElement',
|
|
69
|
+
'swap',
|
|
70
|
+
'withUnsafePointer',
|
|
71
|
+
'withUnsafeMutablePointer',
|
|
72
|
+
'withUnsafeBytes',
|
|
73
|
+
'autoreleasepool',
|
|
74
|
+
'unsafeBitCast',
|
|
75
|
+
'unsafeDowncast',
|
|
76
|
+
'numericCast',
|
|
77
|
+
'type',
|
|
78
|
+
'MemoryLayout',
|
|
79
|
+
'map',
|
|
80
|
+
'flatMap',
|
|
81
|
+
'compactMap',
|
|
82
|
+
'filter',
|
|
83
|
+
'reduce',
|
|
84
|
+
'forEach',
|
|
85
|
+
'contains',
|
|
86
|
+
'first',
|
|
87
|
+
'last',
|
|
88
|
+
'prefix',
|
|
89
|
+
'suffix',
|
|
90
|
+
'dropFirst',
|
|
91
|
+
'dropLast',
|
|
92
|
+
'sorted',
|
|
93
|
+
'reversed',
|
|
94
|
+
'enumerated',
|
|
95
|
+
'joined',
|
|
96
|
+
'split',
|
|
97
|
+
'append',
|
|
98
|
+
'insert',
|
|
99
|
+
'remove',
|
|
100
|
+
'removeAll',
|
|
101
|
+
'removeFirst',
|
|
102
|
+
'removeLast',
|
|
103
|
+
'isEmpty',
|
|
104
|
+
'count',
|
|
105
|
+
'index',
|
|
106
|
+
'startIndex',
|
|
107
|
+
'endIndex',
|
|
108
|
+
'addSubview',
|
|
109
|
+
'removeFromSuperview',
|
|
110
|
+
'layoutSubviews',
|
|
111
|
+
'setNeedsLayout',
|
|
112
|
+
'layoutIfNeeded',
|
|
113
|
+
'setNeedsDisplay',
|
|
114
|
+
'invalidateIntrinsicContentSize',
|
|
115
|
+
'addTarget',
|
|
116
|
+
'removeTarget',
|
|
117
|
+
'addGestureRecognizer',
|
|
118
|
+
'addConstraint',
|
|
119
|
+
'addConstraints',
|
|
120
|
+
'removeConstraint',
|
|
121
|
+
'removeConstraints',
|
|
122
|
+
'NSLocalizedString',
|
|
123
|
+
'Bundle',
|
|
124
|
+
'reloadData',
|
|
125
|
+
'reloadSections',
|
|
126
|
+
'reloadRows',
|
|
127
|
+
'performBatchUpdates',
|
|
128
|
+
'register',
|
|
129
|
+
'dequeueReusableCell',
|
|
130
|
+
'dequeueReusableSupplementaryView',
|
|
131
|
+
'beginUpdates',
|
|
132
|
+
'endUpdates',
|
|
133
|
+
'insertRows',
|
|
134
|
+
'deleteRows',
|
|
135
|
+
'insertSections',
|
|
136
|
+
'deleteSections',
|
|
137
|
+
'present',
|
|
138
|
+
'dismiss',
|
|
139
|
+
'pushViewController',
|
|
140
|
+
'popViewController',
|
|
141
|
+
'popToRootViewController',
|
|
142
|
+
'performSegue',
|
|
143
|
+
'prepare',
|
|
144
|
+
'DispatchQueue',
|
|
145
|
+
'async',
|
|
146
|
+
'sync',
|
|
147
|
+
'asyncAfter',
|
|
148
|
+
'Task',
|
|
149
|
+
'withCheckedContinuation',
|
|
150
|
+
'withCheckedThrowingContinuation',
|
|
151
|
+
'sink',
|
|
152
|
+
'store',
|
|
153
|
+
'assign',
|
|
154
|
+
'receive',
|
|
155
|
+
'subscribe',
|
|
156
|
+
'addObserver',
|
|
157
|
+
'removeObserver',
|
|
158
|
+
'post',
|
|
159
|
+
'NotificationCenter',
|
|
160
|
+
]);
|
|
161
|
+
exports.swiftProvider = (0, language_provider_js_1.defineLanguage)({
|
|
162
|
+
id: index_js_1.SupportedLanguages.Swift,
|
|
163
|
+
extensions: ['.swift'],
|
|
164
|
+
preprocessSource: conditional_directive_preprocess_js_1.preprocessSwiftConditionalDirectives,
|
|
165
|
+
entryPointPatterns: [
|
|
166
|
+
/^viewDidLoad$/,
|
|
167
|
+
/^viewWillAppear$/,
|
|
168
|
+
/^viewDidAppear$/,
|
|
169
|
+
/^viewWillDisappear$/,
|
|
170
|
+
/^viewDidDisappear$/,
|
|
171
|
+
/^application\(/,
|
|
172
|
+
/^scene\(/,
|
|
173
|
+
/^body$/,
|
|
174
|
+
/Coordinator$/,
|
|
175
|
+
/^sceneDidBecomeActive$/,
|
|
176
|
+
/^sceneWillResignActive$/,
|
|
177
|
+
/^didFinishLaunchingWithOptions$/,
|
|
178
|
+
/ViewController$/,
|
|
179
|
+
/^configure[A-Z]/,
|
|
180
|
+
/^setup[A-Z]/,
|
|
181
|
+
/^makeBody$/,
|
|
182
|
+
],
|
|
183
|
+
astFrameworkPatterns: [
|
|
184
|
+
{
|
|
185
|
+
framework: 'uikit',
|
|
186
|
+
entryPointMultiplier: 2.5,
|
|
187
|
+
reason: 'uikit-lifecycle',
|
|
188
|
+
patterns: [
|
|
189
|
+
'viewDidLoad',
|
|
190
|
+
'viewWillAppear',
|
|
191
|
+
'viewDidAppear',
|
|
192
|
+
'UIViewController',
|
|
193
|
+
'@IBOutlet',
|
|
194
|
+
'@IBAction',
|
|
195
|
+
'@objc',
|
|
196
|
+
],
|
|
197
|
+
},
|
|
198
|
+
{
|
|
199
|
+
framework: 'swiftui',
|
|
200
|
+
entryPointMultiplier: 2.8,
|
|
201
|
+
reason: 'swiftui-pattern',
|
|
202
|
+
patterns: [
|
|
203
|
+
'@main',
|
|
204
|
+
'WindowGroup',
|
|
205
|
+
'ContentView',
|
|
206
|
+
'@StateObject',
|
|
207
|
+
'@ObservedObject',
|
|
208
|
+
'@EnvironmentObject',
|
|
209
|
+
'@Published',
|
|
210
|
+
],
|
|
211
|
+
},
|
|
212
|
+
{
|
|
213
|
+
framework: 'vapor',
|
|
214
|
+
entryPointMultiplier: 3.0,
|
|
215
|
+
reason: 'vapor-routing',
|
|
216
|
+
patterns: ['app.get', 'app.post', 'req.content.decode', 'Vapor'],
|
|
217
|
+
},
|
|
218
|
+
],
|
|
219
|
+
treeSitterQueries: tree_sitter_queries_js_1.SWIFT_QUERIES,
|
|
220
|
+
typeConfig: swift_js_2.typeConfig,
|
|
221
|
+
exportChecker: export_detection_js_1.swiftExportChecker,
|
|
222
|
+
importResolver: (0, resolver_factory_js_1.createImportResolver)(swift_js_3.swiftImportConfig),
|
|
223
|
+
callExtractor: (0, generic_js_5.createCallExtractor)(swift_js_7.swiftCallConfig),
|
|
224
|
+
fieldExtractor: (0, generic_js_2.createFieldExtractor)(swift_js_4.swiftConfig),
|
|
225
|
+
methodExtractor: (0, generic_js_3.createMethodExtractor)({
|
|
226
|
+
...swift_js_5.swiftMethodConfig,
|
|
227
|
+
extractFunctionName: swiftExtractFunctionName,
|
|
228
|
+
}),
|
|
229
|
+
variableExtractor: (0, generic_js_4.createVariableExtractor)(swift_js_6.swiftVariableConfig),
|
|
230
|
+
classExtractor: (0, generic_js_1.createClassExtractor)(swift_js_1.swiftClassConfig),
|
|
231
|
+
// ── Swift doc comments (`///`, `/** */`) → description (issue #2270) ──
|
|
232
|
+
descriptionExtractor: (0, ast_helpers_js_1.createLeadingDocDescriptionExtractor)(),
|
|
233
|
+
orderSameNameTypeCandidates: orderSwiftSameNameTypeCandidates,
|
|
234
|
+
builtInNames: BUILT_INS,
|
|
235
|
+
// ── Scope-based resolution hooks (RFC #909 Ring 3, issue #937). See
|
|
236
|
+
// languages/swift/ for the implementations. ──────────────────────
|
|
237
|
+
emitScopeCaptures: index_js_2.emitSwiftScopeCaptures,
|
|
238
|
+
cfgVisitor: (0, swift_js_8.createSwiftCfgVisitor)(),
|
|
239
|
+
interpretImport: index_js_2.interpretSwiftImport,
|
|
240
|
+
interpretTypeBinding: index_js_2.interpretSwiftTypeBinding,
|
|
241
|
+
bindingScopeFor: index_js_2.swiftBindingScopeFor,
|
|
242
|
+
importOwningScope: index_js_2.swiftImportOwningScope,
|
|
243
|
+
receiverBinding: index_js_2.swiftReceiverBinding,
|
|
244
|
+
mergeBindings: (_scope, bindings) => (0, index_js_2.swiftMergeBindings)(bindings),
|
|
245
|
+
arityCompatibility: index_js_2.swiftArityCompatibility,
|
|
246
|
+
});
|