Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

internal: refactor prefer_no_std/prefer_prelude bools into a struct #17252

Merged

Conversation

davidbarsky
Copy link
Contributor

I noticed that there's a large number of functions/arguments during an unrelated change that take two booleans and realized they're probably better off being in a single struct—less error-prone, etc.

Feel free to suggest a better name than ImportPathConfig/close this entirely! I can also make these args enums; just hopefully making this a little more misuse-resistant.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 17, 2024
@Veykril Veykril force-pushed the david/refactor-standalone-bools-into-struct branch from 4da6dbf to 04d9910 Compare May 22, 2024 18:46
@Veykril Veykril force-pushed the david/refactor-standalone-bools-into-struct branch from 04d9910 to dc565d4 Compare May 22, 2024 18:46
@Veykril
Copy link
Member

Veykril commented May 22, 2024

Rebased it given my PR had a bunch of conflicts touching the same parts :) The new ignore_local_imports: bool, remains now though, as its private API and shouldn't belong to that new struct (though that means its also not exposed like the other two were so that should be fine)
@bors r+

@bors
Copy link
Collaborator

bors commented May 22, 2024

📌 Commit dc565d4 has been approved by Veykril

It is now in the queue for this repository.

bors added a commit that referenced this pull request May 22, 2024
…to-struct, r=Veykril

internal: refactor `prefer_no_std`/`prefer_prelude` bools into a struct

I noticed that there's a large number of functions/arguments during an unrelated change that take two booleans and realized they're _probably_ better off being in a single struct—less error-prone, etc.

Feel free to suggest a better name than `ImportPathConfig`/close this entirely! I can also make these args enums; just hopefully making this a little more misuse-resistant.
@bors
Copy link
Collaborator

bors commented May 22, 2024

⌛ Testing commit dc565d4 with merge f5f3b0c...

@bors
Copy link
Collaborator

bors commented May 22, 2024

💔 Test failed - checks-actions

@Veykril Veykril force-pushed the david/refactor-standalone-bools-into-struct branch from dc565d4 to 3eb607c Compare May 22, 2024 19:37
@Veykril
Copy link
Member

Veykril commented May 22, 2024

small rebase mishap
@bors r+

@bors
Copy link
Collaborator

bors commented May 22, 2024

📌 Commit 3eb607c has been approved by Veykril

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented May 22, 2024

⌛ Testing commit 3eb607c with merge 20cfaf5...

bors added a commit that referenced this pull request May 22, 2024
…to-struct, r=Veykril

internal: refactor `prefer_no_std`/`prefer_prelude` bools into a struct

I noticed that there's a large number of functions/arguments during an unrelated change that take two booleans and realized they're _probably_ better off being in a single struct—less error-prone, etc.

Feel free to suggest a better name than `ImportPathConfig`/close this entirely! I can also make these args enums; just hopefully making this a little more misuse-resistant.
@bors
Copy link
Collaborator

bors commented May 22, 2024

💔 Test failed - checks-actions

@Veykril Veykril force-pushed the david/refactor-standalone-bools-into-struct branch from 3eb607c to 3a7dcf9 Compare May 22, 2024 19:57
@Veykril
Copy link
Member

Veykril commented May 22, 2024

@bors r+

@bors
Copy link
Collaborator

bors commented May 22, 2024

📌 Commit 3a7dcf9 has been approved by Veykril

It is now in the queue for this repository.

@bors
Copy link
Collaborator

bors commented May 22, 2024

⌛ Testing commit 3a7dcf9 with merge 870ad35...

@bors
Copy link
Collaborator

bors commented May 22, 2024

☀️ Test successful - checks-actions
Approved by: Veykril
Pushing 870ad35 to master...

@bors bors merged commit 870ad35 into rust-lang:master May 22, 2024
11 checks passed
@davidbarsky davidbarsky deleted the david/refactor-standalone-bools-into-struct branch May 22, 2024 20:15
@davidbarsky davidbarsky restored the david/refactor-standalone-bools-into-struct branch May 22, 2024 20:15
@davidbarsky davidbarsky deleted the david/refactor-standalone-bools-into-struct branch May 22, 2024 20:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants