Conversation
38abf36 to
1fddf33
Compare
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Mutating the supplied file list breaks read-only inputs and malformed trailing-line handling.
Get a fresh assessment by requesting another Copilot review.
Review effort: Balanced
Findings: 1
Open (2)
What changed in this PR
Adds synthetic Swift builtin declarations so Unified name binding can resolve standard types while excluding them from source-only analyses.
Changes:
- Packages and extracts Swift builtin type stubs.
- Adds source-origin filtering for AST, CFG, and tests.
- Updates name-binding expectations for builtin types.
| File | Description |
|---|---|
unified/tools/builtins/types.swift |
Defines synthetic Swift builtin types. |
unified/tools/builtins/BUILD.bazel |
Packages builtin stubs. |
unified/tools/BUILD.bazel |
Adjusts nested tools packaging. |
unified/BUILD.bazel |
Combines extractor, scripts, and builtins under tools. |
unified/extractor/src/extractor.rs |
Adds builtins to extraction inputs. |
unified/ql/lib/codeql/files/FileSystem.qll |
Distinguishes source-root files. |
unified/ql/lib/codeql/unified/internal/Builtins.qll |
Identifies builtin declarations. |
unified/ql/lib/codeql/unified/internal/FacadeAst.qll |
Exposes AST source-origin filtering. |
unified/ql/lib/codeql/unified/internal/ControlFlowGraph.qll |
Excludes external callables from CFG construction. |
unified/ql/test/library-tests/BasicTest/test.ql |
Filters synthetic identifiers. |
unified/ql/test/library-tests/comments/comments.ql |
Filters synthetic comments. |
unified/ql/test/library-tests/definitions/test.swift |
Tests Optional resolution. |
unified/ql/test/library-tests/static-name-binding/explicit-instance-field-access.swift |
Tests Int resolution. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
1fddf33 to
a58ba53
Compare
There was a problem hiding this comment.
Copilot review overview
🟡 Changes recommended
Persistent scratch-file creation breaks repeated indexing, and builtin classification and API exposure are incomplete.
Get a fresh assessment by requesting another Copilot review.
Review effort: Balanced
Findings: 3
Open (3)
Resolved since last review (2)
a58ba53 to
fb87758
Compare
fb87758 to
f32171f
Compare



Needed for type inference.
DCA shows a big improvement for
Percentage of statically resolvable names(from 56.3 % to 69.6 %).