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

Rollup of 9 pull requests #59165

Closed
wants to merge 31 commits into from
Closed

Rollup of 9 pull requests #59165

wants to merge 31 commits into from

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Mar 13, 2019

Successful merges:

Failed merges:

r? @ghost

jordanrh1 and others added 30 commits March 5, 2019 13:56
Remove methods `Attribute::span` and `MetaItem::span` duplicating public fields
This commit adds a regression test for rust-lang#55809 which checks that a
overflow does not occur when evaluating a requirement for async
functions and `&mut` arguments in some specific circumstances.
Rewrite the SelfCtor early and use the replacement Def when
calculating the path_segs.

Note that this also changes which def is seen by the code that
computes user_self_ty and is_alias_variant_ctor; I don't see a
immediate issue with that, but I'm not 100% clear on the
implications.

Fixes rust-lang#57924
… r=sanxiyn

Update compiler_builtins to 0.1.7 to get windows/arm fix
Do not accidentally treat multi-segment meta-items as single-segment

Fixes rust-lang#55168 and many other regressions from rust-lang#50030

Basically, attributes like `#[any::prefix::foo]` were commonly interpreted as `#[foo]` due to `name()` successfully returning the last segment (this applies to nested things as well `#[attr(any::prefix::foo)]`).
Fix generic argument lookup for Self

Rewrite the SelfCtor early and use the replacement Def when
calculating the path_segs.

Note that this also changes which def is seen by the code that
computes user_self_ty and is_alias_variant_ctor; I don't see a
immediate issue with that, but I'm not 100% clear on the
implications.

Fixes rust-lang#57924

r? @eddyb
resolve: Account for new importable entities

Fixes the ICE encountered in rust-lang#58837
r? @Centril
…chton

Consistent naming for duration_float methods and additional f32 methods

`duration_float` tracking issue: rust-lang#54361

New list of methods:
- `as_secs_f64(&self) -> f64`
- `as_secs_f32(&self) -> f32`
- `from_secs_f64(secs: f64) -> Duration`
- `from_secs_f32(secs: f32) -> Duration`
- `mul_f64(self, rhs: f64) -> Duration`
- `mul_f32(self, rhs: f32) -> Duration`
- `div_f64(self, rhs: f64) -> Duration`
- `div_f32(self, rhs: f64) -> Duration`
- `div_duration_f64(self, rhs: Duration) -> f64`
- `div_duration_f32(self, rhs: Duration) -> f32`

With [`num_traits::Float`](https://docs.rs/num-traits/0.2.6/num_traits/float/trait.Float.html) we could've reduced number of methods by factor of two, but unfortunately it's not part of `std`.
Be more discerning on when to attempt suggesting a comma in a macro invocation

Fix rust-lang#58796.
Suggest return lifetime when there's only one named lifetime

Fix rust-lang#29094.
Make std time tests more robust for platform differences

Previously, `time::tests::since_epoch` and `time::tests::system_time_math` would fail if the platform represents a SystemTime as unix epoch + `u64` nanoseconds.

r? @sfackler
[wg-async-await] Add regression test for rust-lang#55809.

Fixes rust-lang#55809.

This PR adds a regression test for rust-lang#55809 which checks that a
overflow does not occur when evaluating a requirement for async
functions and `&mut` arguments in some specific circumstances.
@Centril
Copy link
Contributor Author

Centril commented Mar 13, 2019

@bors r+ p=9

@bors
Copy link
Contributor

bors commented Mar 13, 2019

📌 Commit 3569af1 has been approved by Centril

@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Mar 13, 2019
@bors
Copy link
Contributor

bors commented Mar 13, 2019

🔒 Merge conflict

This pull request and the master branch diverged in a way that cannot be automatically merged. Please rebase on top of the latest master branch, and let the reviewer approve again.

How do I rebase?

Assuming self is your fork and upstream is this repository, you can resolve the conflict following these steps:

  1. git checkout rollup (switch to your branch)
  2. git fetch upstream master (retrieve the latest master)
  3. git rebase upstream/master -p (rebase on top of it)
  4. Follow the on-screen instruction to resolve conflicts (check git status if you got lost).
  5. git push self rollup --force-with-lease (update this PR)

You may also read Git Rebasing to Resolve Conflicts by Drew Blessing for a short tutorial.

Please avoid the "Resolve conflicts" button on GitHub. It uses git merge instead of git rebase which makes the PR commit history more difficult to read.

Sometimes step 4 will complete without asking for resolution. This is usually due to difference between how Cargo.lock conflict is handled during merge and rebase. This is normal, and you should still perform step 5 to update this PR.

Error message
warning: Cannot merge binary files: Cargo.lock (HEAD vs. heads/homu-tmp)
Removing src/test/ui/proc-macro/shadow-builtin.stderr
Removing src/test/ui/proc-macro/shadow-builtin.rs
Auto-merging Cargo.lock
CONFLICT (content): Merge conflict in Cargo.lock
Automatic merge failed; fix conflicts and then commit the result.

@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 Mar 13, 2019
@Centril Centril closed this Mar 13, 2019
@Centril Centril deleted the rollup branch March 13, 2019 21:59
@rust-highfive
Copy link
Collaborator

The job x86_64-gnu-llvm-6.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.
travis_time:end:1a7e7a80:start=1552510285875806500,finish=1552510379015807621,duration=93140001121
$ git checkout -qf FETCH_HEAD
travis_fold:end:git.checkout

Encrypted environment variables have been removed for security reasons.
See https://docs.travis-ci.com/user/pull-requests/#pull-requests-and-security-restrictions
$ export SCCACHE_BUCKET=rust-lang-ci-sccache2
$ export SCCACHE_REGION=us-west-1
$ export GCP_CACHE_BUCKET=rust-lang-ci-cache
Setting environment variables from .travis.yml
---
[01:09:29] .................................................................................................... 4400/5468
[01:09:32] .................................................................................................... 4500/5468
[01:09:36] .................................................................................................... 4600/5468
[01:09:40] ...........i........................................................................................ 4700/5468
[01:09:46] ...........................F........................................................................ 4800/5468
[01:09:53] .................................................................................................... 5000/5468
[01:09:56] .................................................................................................... 5100/5468
[01:10:00] .................................................................................................... 5200/5468
[01:10:03] .................................................................................................... 5300/5468
---
[01:10:07] 
[01:10:07] 1 error: cannot use a built-in attribute through an import
[01:10:07] 2   --> $DIR/cross-crate.rs:7:3
[01:10:07] 3    |
[01:10:07] - LL | #[built_in_attr] //~ ERROR cannot use a built-in attribute through an import
[01:10:07] + LL | #[built_in_attr]
[01:10:07] 6    |
[01:10:07] 7 note: the built-in attribute imported here
[01:10:07] 
[01:10:07] 13 error: cannot use a tool module through an import
[01:10:07] 13 error: cannot use a tool module through an import
[01:10:07] 14   --> $DIR/cross-crate.rs:8:3
[01:10:07] 15    |
[01:10:07] - LL | #[tool_mod::skip] //~ ERROR cannot use a tool module through an import
[01:10:07] + LL | #[tool_mod::skip]
[01:10:07] 18    |
[01:10:07] 19 note: the tool module imported here
[01:10:07] 
[01:10:07] 
[01:10:07] 
[01:10:07] The actual stderr differed from the expected stderr.
[01:10:07] Actual stderr saved to /checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/rust-2018/uniform-paths/cross-crate/cross-crate.stderr
[01:10:07] To update references, rerun the tests and pass the `--bless` flag
[01:10:07] To only update this specific test, also pass `--test-args rust-2018/uniform-paths/cross-crate.rs`
[01:10:07] error: 1 errors occurred comparing output.
[01:10:07] status: exit code: 1
[01:10:07] status: exit code: 1
[01:10:07] command: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "/checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs" "-Zthreads=1" "--target=x86_64-unknown-linux-gnu" "--error-format" "json" "-Zui-testing" "-C" "prefer-dynamic" "-o" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/rust-2018/uniform-paths/cross-crate/a" "-Crpath" "-O" "-Zunstable-options" "-Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--edition=2018" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui/rust-2018/uniform-paths/cross-crate/auxiliary" "-A" "unused"
[01:10:07] ------------------------------------------
[01:10:07] 
[01:10:07] ------------------------------------------
[01:10:07] stderr:
[01:10:07] stderr:
[01:10:07] ------------------------------------------
[01:10:07] {"message":"cannot use a built-in attribute through an import","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs","byte_start":94,"byte_end":107,"line_start":7,"line_end":7,"column_start":3,"column_end":16,"is_primary":true,"text":[{"text":"#[built_in_attr] //~ ERROR cannot use a built-in attribute through an import","highlight_start":3,"highlight_end":16}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"the built-in attribute imported here","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs","byte_start":75,"byte_end":89,"line_start":5,"line_end":5,"column_start":5,"column_end":19,"is_primary":true,"text":[{"text":"use cross_crate::*;","highlight_start":5,"highlight_end":19}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null}],"rendered":"error: cannot use a built-in attribute through an import\n  --> /checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs:7:3\n   |\nLL | #[built_in_attr] //~ ERROR cannot use a built-in attribute through an import\n   |   ^^^^^^^^^^^^^\n   |\nnote: the built-in attribute imported here\n  --> /checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs:5:5\n   |\nLL | use cross_crate::*;\n   |     ^^^^^^^^^^^^^^\n\n"}
[01:10:07] {"message":"cannot use a tool module through an import","code":null,"level":"error","spans":[{"file_name":"/checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs","byte_start":171,"byte_end":179,"line_start":8,"line_end":8,"column_start":3,"column_end":11,"is_primary":true,"text":[{"text":"#[tool_mod::skip] //~ ERROR cannot use a tool module through an import","highlight_start":3,"highlight_end":11}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[{"message":"the tool module imported here","code":null,"level":"note","spans":[{"file_name":"/checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs","byte_start":75,"byte_end":89,"line_start":5,"line_end":5,"column_start":5,"column_end":19,"is_primary":true,"text":[{"text":"use cross_crate::*;","highlight_start":5,"highlight_end":19}],"label":null,"suggested_replacement":null,"suggestion_applicability":null,"expansion":null}],"children":[],"rendered":null}],"rendered":"error: cannot use a tool module through an import\n  --> /checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs:8:3\n   |\nLL | #[tool_mod::skip] //~ ERROR cannot use a tool module through an import\n   |   ^^^^^^^^\n   |\nnote: the tool module imported here\n  --> /checkout/src/test/ui/rust-2018/uniform-paths/cross-crate.rs:5:5\n   |\nLL | use cross_crate::*;\n   |     ^^^^^^^^^^^^^^\n\n"}
[01:10:07] 
[01:10:07] ------------------------------------------
[01:10:07] 
[01:10:07] thread '[ui] ui/rust-2018/uniform-paths/cross-crate.rs' panicked at 'explicit panic', src/tools/compiletest/src/runtest.rs:3325:9
---
[01:10:07] 
[01:10:07] thread 'main' panicked at 'Some tests failed', src/tools/compiletest/src/main.rs:496:22
[01:10:07] 
[01:10:07] 
[01:10:07] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0-tools-bin/compiletest" "--compile-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib" "--run-lib-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/lib/rustlib/x86_64-unknown-linux-gnu/lib" "--rustc-path" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2/bin/rustc" "--src-base" "/checkout/src/test/ui" "--build-base" "/checkout/obj/build/x86_64-unknown-linux-gnu/test/ui" "--stage-id" "stage2-x86_64-unknown-linux-gnu" "--mode" "ui" "--target" "x86_64-unknown-linux-gnu" "--host" "x86_64-unknown-linux-gnu" "--llvm-filecheck" "/usr/lib/llvm-6.0/bin/FileCheck" "--host-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--target-rustcflags" "-Crpath -O -Zunstable-options  -Lnative=/checkout/obj/build/x86_64-unknown-linux-gnu/native/rust-test-helpers" "--docck-python" "/usr/bin/python2.7" "--lldb-python" "/usr/bin/python2.7" "--gdb" "/usr/bin/gdb" "--quiet" "--llvm-version" "6.0.0\n" "--system-llvm" "--cc" "" "--cxx" "" "--cflags" "" "--llvm-components" "" "--llvm-cxxflags" "" "--adb-path" "adb" "--adb-test-dir" "/data/tmp/work" "--android-cross-path" "" "--color" "always"
[01:10:07] 
[01:10:07] 
[01:10:07] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test
[01:10:07] Build completed unsuccessfully in 0:04:16
[01:10:07] Build completed unsuccessfully in 0:04:16
[01:10:07] Makefile:48: recipe for target 'check' failed
[01:10:07] make: *** [check] Error 1
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 2.
travis_time:start:085a298a
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
Wed Mar 13 22:03:16 UTC 2019

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)

@Centril Centril added the rollup A PR which is a rollup label Oct 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants