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

Add HirId to VisibilityKind::Restricted #52911

Merged
merged 1 commit into from
Aug 7, 2018

Conversation

Mark-Simulacrum
Copy link
Member

I'm not confident that these changes are correct -- mostly just tried to copy previous PRs.

Specifically, it's unclear to me if/how to remove the NodeId now that we have HirIds in more structs; is that a all-at-once change that'll happen later?

@rust-highfive
Copy link
Collaborator

r? @oli-obk

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jul 31, 2018
@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
[00:33:28]    Compiling rand v0.4.2
[00:33:28]    Compiling aho-corasick v0.6.6
[00:33:31]    Compiling tempfile v3.0.2
[00:33:51]    Compiling minifier v0.0.14
[00:33:56] error[E0063]: missing field `hir_ref_id` in initializer of `rustc::hir::TraitRef`
[00:33:56]    --> librustdoc/clean/auto_trait.rs:171:42
[00:33:56]     |
[00:33:56] 171 |                             let trait_ = hir::TraitRef {
[00:33:56]     |                                          ^^^^^^^^^^^^^ missing `hir_ref_id`
 1% /dev
tmpfs           1.5G  284K  1.5G   1% /run
/dev/sda1        30G  9.2G   19G  33% /
none            4.0K     0  4.0K   0% /sys/fs/cgroup
---
40556 ./src/llvm/lib/Target
37368 ./obj/build/x86_64-unknown-linux-gnu/stage0-std
36204 ./obj/build/x86_64-unknown-linux-gnu/stage1-std/release
36204 ./obj/build/x86_64-unknown-linux-gnu/stage0-std/release
3583load off' -iex 'dir src/' -iex 'set sysroot .' -ex bt -ex q; echo travis_fold":"end:crashlog; fi; done || true
travis_fold:end:after_failure.4
travis_fold:start:after_failure.5
travis_time:start:239c2e33
travis_time:start:239c2e33
$ cat ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers || true
cat: ./obj/build/x86_64-unknown-linux-gnu/native/asan/build/lib/asan/clang_rt.asan-dynamic-i386.vers: No such file or directory
travis_fold:end:after_failure.5
travis_fold:start:after_failure.6
travis_time:start:0b662e60
$ dmesg | grep -i kill

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-5.0 of your PR failed on Travis (raw log). Through arcane magic we have determined that the following fragments from the build log may contain information about the problem.

Click to expand the log.
[00:34:45]    Compiling aho-corasick v0.6.6
[00:34:49]    Compiling tempfile v3.0.2
[00:35:09]    Compiling minifier v0.0.14
[00:35:11]    Compiling rustdoc v0.0.0 (file:///checkout/src/librustdoc)
[00:35:15] error[E0063]: missing field `hir_ref_id` in initializer of `rustc::hir::TraitRef`
[00:35:15]    --> librustdoc/clean/auto_trait.rs:301:26
[00:35:15]     |
[00:35:15] 301 |             let trait_ = hir::TraitRef {
[00:35:15]     |                          ^^^^^^^^^^^^^ missing `hir_ref_id`
 ./src/test/ui
18556 ./obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu
18552 ./obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu/release
18200 ./obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu/release/deps
---
travis_time:end:022ebf2e:start=1533130711145186880,finish=1533130711153628992,duration=8442112
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:2093bb7e
$ ln -s . checkout && for CORE in obj/cores/core.*; do EXE=$(echo $CORE | sed 's|obj/cores/core\.[0-9]*\.!checkout!\(.*\)|\1|;y|!|/|'); if [ -f "$EXE" ]; then printf travis_fold":start:crashlog\n\

I'm a bot! I can only do what humans tell me to, so if this was not helpful or you have suggestions for improvements, please ping or otherwise contact @TimNN. (Feature Requests)

@oli-obk
Copy link
Contributor

oli-obk commented Aug 7, 2018

The changes look good to me.

I think we can slowly phase out node IDs by porting all their use sites to HIR ID operations. If a field is unused, just remove it

r=me with a rebase

@Mark-Simulacrum
Copy link
Member Author

Right, my question was for example if we can/should remove the node id hash here: https://github.com/rust-lang/rust/blob/a3769c43fe1ff12c1e6610872d2660ef93b22c31/src/librustc/ich/impls_hir.rs#L729-L730, leaving just the HIR ID hash.

@Mark-Simulacrum
Copy link
Member Author

@bors r=oli-obk

@bors
Copy link
Contributor

bors commented Aug 7, 2018

📌 Commit 3baec3c has been approved by oli-obk

@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 Aug 7, 2018
@oli-obk
Copy link
Contributor

oli-obk commented Aug 7, 2018

I'd do that in the same step as removing the field.

@bors
Copy link
Contributor

bors commented Aug 7, 2018

⌛ Testing commit 3baec3c with merge e90dc6f...

bors added a commit that referenced this pull request Aug 7, 2018
Add HirId to VisibilityKind::Restricted

I'm not confident that these changes are correct -- mostly just tried to copy previous PRs.

Specifically, it's unclear to me if/how to remove the NodeId now that we have HirIds in more structs; is that a all-at-once change that'll happen later?
@bors
Copy link
Contributor

bors commented Aug 7, 2018

☀️ Test successful - status-appveyor, status-travis
Approved by: oli-obk
Pushing e90dc6f to master...

@bors bors merged commit 3baec3c into rust-lang:master Aug 7, 2018
@Mark-Simulacrum Mark-Simulacrum deleted the visibility-hirid branch June 8, 2019 13:49
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.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants