mirror of
https://github.com/abhigyanpatwari/GitNexus.git
synced 2026-09-07 08:26:11 +00:00
* fix(php): phtml scope synthesis with full-file range + O(1) Step 4 lookup (#1801, #1803) Address PR #1801 review findings and complete #1803 fix: scope-extractor.ts: - Synthetic Module scope uses full-file range (computed from existing drafts) so positionIndex containment works for top-level references in ERROR-root .phtml files - Orphan scope re-parenting done on drafts in extract() by replacing with new drafts — no mutation of readonly fields, no PHP-specific logic in shared buildScopeTree - Dead matchCount parameter removed from ensureModuleScope namespace-siblings.ts: - Step 4 parsedFiles.find() replaced with pre-built Map for O(1) lookup (was O(n²) with 16K files = ~256M comparisons) * test(php): add pipeline benchmark for scaling regression detection Synthetic PHP fixture generator (N files × M namespaces × K classes) with cross-namespace imports and calls. Measures wall-clock, peak heap, node/edge counts at 100/250/500 file scales with worker pool enabled. Results on current branch: - 100 files: 982ms, 65MB (9.8ms/file) - 250 files: 1310ms, 70MB (5.2ms/file) - 500 files: 2006ms, 92MB (4.0ms/file) - Scaling: sublinear (0.53x-0.77x ratio) Gated behind GITNEXUS_BENCH=1 so it does not run in normal CI. * chore: trigger CI * fix: prettier formatting + update scope-extractor test for synthesis behavior * fix: extend synthetic Module range to all captures + update integration test Address CI failure and review findings: - ensureModuleScope now computes range from ALL captures (scope, declaration, reference, type-binding) not just scope drafts. This ensures top-level references after the last inner scope are covered. - Update parse-worker-scope-integration test for synthesis behavior. - Update extract() docstring to document synthesis contract. --------- Co-authored-by: Test <test@example.com> Co-authored-by: Gergő Magyar <gergomagyar@icloud.com> |
||
|---|---|---|
| .. | ||
| fixtures | ||
| helpers | ||
| integration | ||
| unit | ||
| utils | ||