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

Rename rustc_mir_build::build to builder #134365

Merged
merged 2 commits into from
Dec 17, 2024
Merged

Conversation

Zalathar
Copy link
Contributor

@Zalathar Zalathar commented Dec 16, 2024

GitHub's “Go to file” feature silently ignores all files in this module, presumably because they are in a directory named build, which is mistaken for a build-output directory. That makes it meaningfully harder to view those files and their history via GitHub.

This PR sidesteps that issue by renaming build to builder, which in context has basically the same meaning, but can't be mistaken for a build-output directory.


Extracted from #133404, after #133592 changed the .gitignore rule from build/ to /build. The problem of GitHub ignoring these files still exists even after that change, which suggests that GitHub's behaviour is a hard-coded heuristic that isn't influenced by the repository's git settings.

Currently this PR doesn't include the tidy rule forbidding build as a module name, but that could be added if people think it's a good idea.

@rustbot
Copy link
Collaborator

rustbot commented Dec 16, 2024

r? @cjgillot

rustbot has assigned @cjgillot.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot 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 Dec 16, 2024
@@ -11,7 +11,7 @@
#![warn(unreachable_pub)]
// tidy-alphabetical-end

mod build;
mod builder;
Copy link
Contributor

Choose a reason for hiding this comment

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

Please add a comment here, e.g. "This used to be called build, but that causes GitHub's “Go to file” feature to silently ignore all files in this module, presumably because they are in a directory named build, which is mistaken for a build-output directory."

r=me with that change.

@Zalathar Zalathar assigned nnethercote and unassigned cjgillot Dec 16, 2024
@Zalathar
Copy link
Contributor Author

@bors r=nnethercote

@bors
Copy link
Contributor

bors commented Dec 16, 2024

📌 Commit 6af1afe has been approved by nnethercote

It is now in the queue for this repository.

@bors bors 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 Dec 16, 2024
@jieyouxu
Copy link
Member

jieyouxu commented Dec 16, 2024

@Zalathar are u sure this is still a problem in github ui, as we changed gitignore from

build/

to

/build

It seems plausible that github has special handling for "build" named dirs, but I suspect that is from gitignore?

@bors r- (sorry one question)

r=@nnethercote again if this is still a problem.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Dec 16, 2024
@Zalathar
Copy link
Contributor Author

@jieyouxu Yeah, it's still a problem even after #133592, which is why I think it's a hard-coded heuristic that doesn't depend on .gitignore.

(I edited the PR description to make this more clear.)

@jieyouxu
Copy link
Member

Thanks, that is very funny.

@bors r=@nnethercote

@bors
Copy link
Contributor

bors commented Dec 16, 2024

📌 Commit 6af1afe has been approved by nnethercote

It is now in the queue for this repository.

@bors bors 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Dec 16, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 16, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#134314 (Make sure to use normalized ty for unevaluated const in default struct value)
 - rust-lang#134342 (crashes: more tests)
 - rust-lang#134357 (Fix `trimmed_def_paths` ICE in the function ptr comparison lint)
 - rust-lang#134369 (Update spelling of "referring")
 - rust-lang#134372 (Disable `tests/ui/associated-consts/issue-93775.rs` on windows msvc)

Failed merges:

 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Contributor

bors commented Dec 16, 2024

☔ The latest upstream changes (presumably #134374) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Dec 16, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 16, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#134202 (Remove `rustc::existing_doc_keyword` lint)
 - rust-lang#134354 (Handle fndef rendering together with signature rendering)
 - rust-lang#134368 (Use links to edition guide for edition migrations)
 - rust-lang#134371 (Check for array lengths that aren't actually `usize`)
 - rust-lang#134378 (An octuple of polonius fact generation cleanups)

Failed merges:

 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)

r? `@ghost`
`@rustbot` modify labels: rollup
@Zalathar
Copy link
Contributor Author

Rebased to fix trivial conflict; no changes.

@bors r=nnethercote

@bors
Copy link
Contributor

bors commented Dec 16, 2024

📌 Commit fb0f329 has been approved by nnethercote

It is now in the queue for this repository.

@bors bors 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Dec 16, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 16, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#134202 (Remove `rustc::existing_doc_keyword` lint)
 - rust-lang#134354 (Handle fndef rendering together with signature rendering)
 - rust-lang#134368 (Use links to edition guide for edition migrations)
 - rust-lang#134371 (Check for array lengths that aren't actually `usize`)
 - rust-lang#134378 (An octuple of polonius fact generation cleanups)

Failed merges:

 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 16, 2024
…iaskrgr

Rollup of 5 pull requests

Successful merges:

 - rust-lang#134202 (Remove `rustc::existing_doc_keyword` lint)
 - rust-lang#134354 (Handle fndef rendering together with signature rendering)
 - rust-lang#134368 (Use links to edition guide for edition migrations)
 - rust-lang#134371 (Check for array lengths that aren't actually `usize`)
 - rust-lang#134378 (An octuple of polonius fact generation cleanups)

Failed merges:

 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Contributor

bors commented Dec 17, 2024

☔ The latest upstream changes (presumably #134395) made this pull request unmergeable. Please resolve the merge conflicts.

@bors bors added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Dec 17, 2024
@Zalathar
Copy link
Contributor Author

Rebased again.

@bors r=nnethercote

@bors
Copy link
Contributor

bors commented Dec 17, 2024

📌 Commit c58219b has been approved by nnethercote

It is now in the queue for this repository.

@bors bors 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Dec 17, 2024
jhpratt added a commit to jhpratt/rust that referenced this pull request Dec 17, 2024
Rename `rustc_mir_build::build` to `builder`

GitHub's “Go to file” feature silently ignores all files in this module, presumably because they are in a directory named `build`, which is mistaken for a build-output directory. That makes it meaningfully harder to view those files and their history via GitHub.

This PR sidesteps that issue by renaming `build` to `builder`, which in context has basically the same meaning, but can't be mistaken for a build-output directory.

---

Extracted from rust-lang#133404, after rust-lang#133592 changed the .gitignore rule from `build/` to `/build`. The problem of GitHub ignoring these files still exists even after that change, which suggests that GitHub's behaviour is a hard-coded heuristic that isn't influenced by the repository's git settings.

Currently this PR doesn't include the tidy rule forbidding `build` as a module name, but that could be added if people think it's a good idea.
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 17, 2024
Rollup of 9 pull requests

Successful merges:

 - rust-lang#133265 (Add a range argument to vec.extract_if)
 - rust-lang#134202 (Remove `rustc::existing_doc_keyword` lint)
 - rust-lang#134354 (Handle fndef rendering together with signature rendering)
 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)
 - rust-lang#134368 (Use links to edition guide for edition migrations)
 - rust-lang#134388 (Update books)
 - rust-lang#134397 (rustc_borrowck: Suggest changing `&raw const` to `&raw mut` if applicable)
 - rust-lang#134398 (AIX: add alignment info for test)
 - rust-lang#134400 (Fix some comments related to upvars handling)

Failed merges:

 - rust-lang#134399 (Do not do if ! else, use unnegated cond and swap the branches instead)

r? `@ghost`
`@rustbot` modify labels: rollup
bors added a commit to rust-lang-ci/rust that referenced this pull request Dec 17, 2024
Rollup of 10 pull requests

Successful merges:

 - rust-lang#134202 (Remove `rustc::existing_doc_keyword` lint)
 - rust-lang#134354 (Handle fndef rendering together with signature rendering)
 - rust-lang#134365 (Rename `rustc_mir_build::build` to `builder`)
 - rust-lang#134368 (Use links to edition guide for edition migrations)
 - rust-lang#134397 (rustc_borrowck: Suggest changing `&raw const` to `&raw mut` if applicable)
 - rust-lang#134398 (AIX: add alignment info for test)
 - rust-lang#134400 (Fix some comments related to upvars handling)
 - rust-lang#134406 (Fix `-Z input-stats` ordering)
 - rust-lang#134409 (bootstrap: fix a comment)
 - rust-lang#134412 (small borrowck cleanup)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 7e72c3e into rust-lang:master Dec 17, 2024
6 checks passed
@rustbot rustbot added this to the 1.85.0 milestone Dec 17, 2024
@Zalathar Zalathar deleted the builder branch December 17, 2024 14:50
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Dec 17, 2024
Rollup merge of rust-lang#134365 - Zalathar:builder, r=nnethercote

Rename `rustc_mir_build::build` to `builder`

GitHub's “Go to file” feature silently ignores all files in this module, presumably because they are in a directory named `build`, which is mistaken for a build-output directory. That makes it meaningfully harder to view those files and their history via GitHub.

This PR sidesteps that issue by renaming `build` to `builder`, which in context has basically the same meaning, but can't be mistaken for a build-output directory.

---

Extracted from rust-lang#133404, after rust-lang#133592 changed the .gitignore rule from `build/` to `/build`. The problem of GitHub ignoring these files still exists even after that change, which suggests that GitHub's behaviour is a hard-coded heuristic that isn't influenced by the repository's git settings.

Currently this PR doesn't include the tidy rule forbidding `build` as a module name, but that could be added if people think it's a good idea.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant 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.

6 participants