Skip to content

Unified: Extract Swift some or any type - #23057

Merged
paldepind merged 4 commits into
mainfrom
unified/swift-some-or-any-type
Nov 11, 2026
Merged

paldepind merged 4 commits into
mainfrom
unified/swift-some-or-any-type

Conversation

@paldepind

Copy link
Copy Markdown
Contributor

No description provided.

paldepind and others added 2 commits November 9, 2026 14:17
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 89a32053-c825-435d-bc04-d901b469ccfa
@paldepind
paldepind marked this pull request as ready for review November 9, 2026 13:54
@paldepind
paldepind requested a review from a team as a code owner November 9, 2026 13:54
Copilot AI auto review requested due to automatic review settings November 9, 2026 13:54

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The review identifies no active issues with the added Swift some and any type support.

No open issues 🎉

What changed in this PR

Adds support for Swift some and any types in the unified extractor, preserving their modifiers and underlying constraints instead of emitting unsupported nodes.

Changes:

  • Translates both type forms into modified_type_expr nodes.
  • Adds corpus tests and expected output for some parameters and return types, and an any variable type.
File Description
unified/​extractor/​tests/​corpus/​swift/​types/​some-type.swift Tests some parameter and return types.
unified/​extractor/​tests/​corpus/​swift/​types/​some-type.output Records expected parsing and extraction for some.
unified/​extractor/​tests/​corpus/​swift/​types/​any-type.swift Tests an any variable type.
unified/​extractor/​tests/​corpus/​swift/​types/​any-type.output Records expected parsing and extraction for any.
unified/​extractor/​src/​languages/​swift/​swift.rs Adds structured translation for someOrAnyType and removes its unsupported fallback.

Review effort: Balanced (auto)

@geoffw0

geoffw0 commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Changes look reasonable to me.

  • you seem to have fixed a missing result in the type inference test. 👍
  • can we have a DCA run?

@paldepind
paldepind requested a review from a team as a code owner November 10, 2026 11:51
@paldepind

Copy link
Copy Markdown
Contributor Author

I've update the tests and started a DCA run: https://github.com/github/codeql-dca-main/issues/40571

@paldepind

Copy link
Copy Markdown
Contributor Author

DCA seems fine.

asgerf
asgerf previously approved these changes Nov 11, 2026
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 3a0ac853-3f88-4fe6-92d3-62af531b7753
@paldepind

Copy link
Copy Markdown
Contributor Author

Needs re-approval after merging main.

@github github deleted a comment from craneh352-crypto Nov 11, 2026
@paldepind
paldepind merged commit b37f9db into main Nov 11, 2026
10 checks passed
@paldepind
paldepind deleted the unified/swift-some-or-any-type branch November 11, 2026 10:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants