Skip to content

rustc_public: add with_cx() to CompilerInterface - #157116

Merged
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
makai410:with-tcx-refactor
May 30, 2026
Merged

rustc_public: add with_cx() to CompilerInterface#157116
rust-bors[bot] merged 1 commit into
rust-lang:mainfrom
makai410:with-tcx-refactor

Conversation

@makai410

Copy link
Copy Markdown
Member

Changes a bunch of:

let cx = self.cx.borrow();letmut tables = self.tables.borrow_mut();

to:

with_cx(|tables, cx| { ...})

in compiler_interface.rs.

r? @celinval

@rustbot

Copy link
Copy Markdown
Collaborator

This PR changes rustc_public

cc @oli-obk, @celinval, @ouz-a

@rustbotrustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 29, 2026

@oli-obkoli-obk 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.

@rust-bors

rust-borsBot commented May 29, 2026

Copy link
Copy Markdown
Contributor

📌 Commit f6cbfd9 has been approved by oli-obk

It is now in the queue for this repository.

🌲 The tree is currently closed for pull requests below priority 1. This pull request will be tested once the tree is reopened.

@rust-borsrust-borsBot added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels May 29, 2026
rust-borsBot pushed a commit that referenced this pull request May 29, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
rust-borsBot pushed a commit that referenced this pull request May 29, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
rust-borsBot pushed a commit that referenced this pull request May 29, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
rust-borsBot pushed a commit that referenced this pull request May 29, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
rust-borsBot pushed a commit that referenced this pull request May 29, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
rust-borsBot pushed a commit that referenced this pull request May 30, 2026
…uwer
Rollup of 16 pull requests
Successful merges:
- #149195 (resolve: Partially convert `ambiguous_glob_imports` lint into a hard error)
- #156960 (Some cleanups around passing extra lifetime params from the resolver to ast lowering)
- #156963 (definitions: remove `DefPathTable`, use `LocalDefId` instead of `DefIndex`)
- #157053 (Eagerly resolve delegations in late resolution)
- #157068 (NVPTX: Remove the unstable ptx linker flavor)
- #157076 (Various proc-macro related code cleanups)
- #157106 (add ABI check logic for wasm)
- #154835 (std::offload sharedmem)
- #157065 (Stabilize `Path::is_empty`)
- #157088 (Improve suggestions for malformed deprecated attribute)
- #157098 (Add the `clflushopt` x86 target feature)
- #157103 (Add reproducibly failing tests for parallel frontend)
- #157111 (Update target maintainer for x86_64-unknown-linux-none)
- #157116 (rustc_public: add `with_cx()` to `CompilerInterface`)
- #157119 (ast_lowering: Simplify `resolve_pin_drop_sugar_impl_item`)
- #157120 (Cleanups around attribute target checking)
Failed merges:
- #157100 (Some more per owner things)
@rust-bors
rust-borsBot merged commit 75223c5 into rust-lang:mainMay 30, 2026
12 checks passed
@rustbotrustbot added this to the 1.98.0 milestone May 30, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

S-waiting-on-borsStatus: Waiting on bors to run and complete tests. Bors will change the label on completion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@makai410@rustbot@oli-obk@celinval