Skip to content

Unified: use link_deps for native deps of swift_syntax_rs - #22569

Merged
redsun82 merged 2 commits into
mainfrom
redsun82-potential-giggle
Sep 15, 2026
Merged

redsun82 merged 2 commits into
mainfrom
redsun82-potential-giggle

Conversation

@redsun82

Copy link
Copy Markdown
Contributor

rules_rust now warns on every build that C++ libraries in deps are deprecated and will stop working:

WARNING: Target @@ql+//unified/swift-syntax-rs:static_runtime_group_start in 'deps' of
@@ql+//unified/swift-syntax-rs:swift_syntax_rs is a C++ library. Only Rust targets are
allowed in 'deps'. Please use 'link_deps' for manual FFI linkage.

All entries in that select are CcInfo-only targets (the two linker-group cc_library shims and the swift_library FFI shim), so they move wholesale to link_deps. rules_rust appends link_deps after deps and preserves list order, so the --start-group / --end-group sequencing is unaffected.

Verified bazel aquery link arguments for swift-syntax-parse are byte-identical before and after, under both the default and the static_swift_runtime platform.

`rules_rust` deprecated C++ libraries in `deps`, warning on every build.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot AI balanced review requested due to automatic review settings September 15, 2026 10:10
@redsun82
redsun82 requested a review from a team as a code owner September 15, 2026 10:10

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.

Copilot review overview

🟢 Approval recommended

The targeted migration matches rules_rust semantics and preserves existing linkage behavior.

Review tier: Balanced
Findings: None

What changed in this PR

Moves Swift native FFI dependencies to the supported rules_rust attribute while preserving linker ordering.

Changes:

  • Replaces deps with link_deps for native Swift/C++ dependencies.
  • Eliminates the rules_rust deprecation warning.
File Description
unified/​swift-syntax-rs/​BUILD.bazel Uses link_deps for native dependencies.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

@asgerf asgerf 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.

Thanks!

@redsun82
redsun82 merged commit 9681f90 into main Sep 15, 2026
11 checks passed
@redsun82
redsun82 deleted the redsun82-potential-giggle branch September 15, 2026 10:53
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.

3 participants