Skip to content

Scan a file for its function and constant declarations - #393

Open
Firehed wants to merge 10 commits into
mainfrom
slice/S3.7b
Open

Scan a file for its function and constant declarations#393
Firehed wants to merge 10 commits into
mainfrom
slice/S3.7b

Conversation

@Firehed

@Firehed Firehed commented Aug 3, 2026

Copy link
Copy Markdown
Owner

Slice S3.7b (#390). DeclarationScanner reads the functions and constants a parsed
file declares, so S3.7d can derive a name→file index for the two symbol namespaces
Composer cannot address by name.

  • Qualified names come from namespacedName (set by NameResolver during
    ParserService::parse()), not hand-tracked Stmt\Namespace_ — the shape SC.3 is
    removing elsewhere.
  • Covered: namespaced and global declarations, every declarator of a multi-name const,
    literal define() in any casing, and declarations nested in a conditional (the polyfill
    shape, which a top-level-only walk would drop).
  • Out of scope, per Plan 0002 §3's locate-only limitation: a computed define() name, and
    anything reached only through a require/include.

QualifiedName lands here rather than in S3.7c as the manifest said — the scanner is its
first caller. Manifest corrected in this branch; fromClassName() is left for S3.7c,
where FilesystemBackend needs it.

@codecov

codecov Bot commented Aug 3, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 98.59%. Comparing base (12a702a) to head (b68b848).
✅ All tests successful. No failed tests found.

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #393      +/-   ##
============================================
+ Coverage     98.58%   98.59%   +0.01%     
- Complexity     1758     1774      +16     
============================================
  Files           116      119       +3     
  Lines          4451     4488      +37     
============================================
+ Hits           4388     4425      +37     
  Misses           63       63              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant