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 8 pull requests #57850

Closed
wants to merge 26 commits into from
Closed

Rollup of 8 pull requests #57850

wants to merge 26 commits into from

Conversation

Centril
Copy link
Contributor

@Centril Centril commented Jan 23, 2019

Successful merges:

Failed merges:

r? @ghost

Xaeroxe and others added 26 commits December 28, 2018 14:15
Attempt to recover from parse errors while parsing a struct's literal fields
by skipping tokens until a comma or the closing brace is found. This allows
errors in other fields to be reported.
This commit adds a error (and accompanying machine applicable
suggestion) for trailing angle brackets on function calls with a
turbofish.
This commit pluralizes error messages when more than a single trailing
`>` character is present.
This commit extends the trailing `>` detection to also work for paths
such as `Foo::<Bar>>:Baz`.

This involves making the existing check take the token that is expected
to follow the path being checked as a parameter.

Care is taken to ensure that this only happens on the construction of a
whole path segment and not a partial path segment (during recursion).

Through this enhancement, it was also observed that the ordering of
right shift token and greater than tokens was overfitted to the examples
being tested.

In practice, given a sequence of `>` characters: `>>>>>>>>>`
..then they will be split into `>>` eagerly: `>> >> >> >> >`.
..but when a `<` is prepended, then the first `>>` is split:
`<T> > >> >> >> >`
..and then when another `<` is prepended, a right shift is first again:
`Vec<<T>> >> >> >> >`

In the previous commits, a example that had two `<<` characters was
always used and therefore it was incorrectly assumed that `>>` would
always be first - but when there is a single `<`, this is not the case.
Add 'partition_at_index/_by/_by_key' for slices.

This is an analog to C++'s std::nth_element (a.k.a. quickselect).

Corresponds to tracking bug rust-lang#55300.
Update std/lib.rs docs to reflect Rust 2018 usage

Fixes rust-lang#56544

This paragraph was written for Rust 2015.  Since 2018 has been stable for a while I think we can update it.
…ertj

Merge visitors in AST validation

Cuts runtime for AST validation on `syntex_syntax` from 31.5 ms to 17 ms.
…avidtwco

Recover from parse errors in literal struct fields and incorrect float literals

Fix rust-lang#52496.
Explain type mismatch cause pointing to return type when it is `impl Trait`

Fix rust-lang#57743.
Use structured suggestion in stead of notes
Add error for trailing angle brackets.

Fixes rust-lang#54521.

This PR adds a error (and accompanying machine applicable
suggestion) for trailing angle brackets on function calls with a
turbofish.

r? @estebank
@Centril
Copy link
Contributor Author

Centril commented Jan 23, 2019

@bors r+ p=8

@bors
Copy link
Contributor

bors commented Jan 23, 2019

📌 Commit 569fa82 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 Jan 23, 2019
@bors
Copy link
Contributor

bors commented Jan 23, 2019

⌛ Testing commit 569fa82 with merge 9a3a323ec8d2ba7c82d3931564c4aa68b8d1ba47...

@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 Jan 23, 2019
@bors
Copy link
Contributor

bors commented Jan 23, 2019

⌛ Testing commit 569fa82 with merge 2de0099a99f33099b2e3e9d3eaa0755e0caae107...

@bors
Copy link
Contributor

bors commented Jan 23, 2019

💔 Test failed - checks-travis

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jan 23, 2019
@rust-highfive
Copy link
Collaborator

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.
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:07] null
[00:12:08] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:10] Sending build context to Docker daemon  483.3kB
[00:12:10] Step 1/18 : FROM ubuntu:16.04
[00:12:10]  ---> 7e87e2b3bf7a
[00:12:10] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:19] null
[00:12:20] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:22] Sending build context to Docker daemon  483.3kB
[00:12:22] Step 1/18 : FROM ubuntu:16.04
[00:12:22]  ---> 7e87e2b3bf7a
[00:12:22] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:31] null
[00:12:32] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:35] Sending build context to Docker daemon  483.3kB
[00:12:35] Step 1/18 : FROM ubuntu:16.04
[00:12:35]  ---> 7e87e2b3bf7a
[00:12:35] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:45] null
[00:12:46] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:50] Sending build context to Docker daemon  483.3kB
[00:12:50] Step 1/18 : FROM ubuntu:16.04
[00:12:50]  ---> 7e87e2b3bf7a
[00:12:50] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:59] null
[00:13:00] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
travis_time:end:05a6f34e:start=1548211081944419566,finish=1548211862530559801,duration=780586140235
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 1.
travis_time:start:1c67b61b
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:0e67226f:start=1548211863423073310,finish=1548211863432032933,duration=8959623
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:02f81457
$ 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\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load 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:0ffa1838
travis_time:start:0ffa1838
$ 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:0f3d9c7a
$ 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)

@Centril
Copy link
Contributor Author

Centril commented Jan 23, 2019

@bors retry

@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 Jan 23, 2019
@bors
Copy link
Contributor

bors commented Jan 23, 2019

⌛ Testing commit 569fa82 with merge 7d481255e28ce0e00a57b687c28411f209192719...

@bors
Copy link
Contributor

bors commented Jan 23, 2019

💔 Test failed - checks-travis

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jan 23, 2019
@rust-highfive
Copy link
Collaborator

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.
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:18] null
[00:12:19] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:20] Sending build context to Docker daemon  483.3kB
[00:12:20] Step 1/18 : FROM ubuntu:16.04
[00:12:20]  ---> 7e87e2b3bf7a
[00:12:20] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:29] null
[00:12:30] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:32] Sending build context to Docker daemon  483.3kB
[00:12:32] Step 1/18 : FROM ubuntu:16.04
[00:12:32]  ---> 7e87e2b3bf7a
[00:12:32] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:41] null
[00:12:42] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:45] Sending build context to Docker daemon  483.3kB
[00:12:45] Step 1/18 : FROM ubuntu:16.04
[00:12:45]  ---> 7e87e2b3bf7a
[00:12:45] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:12:54] null
[00:12:55] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
[00:12:59] Sending build context to Docker daemon  483.3kB
[00:12:59] Step 1/18 : FROM ubuntu:16.04
[00:12:59]  ---> 7e87e2b3bf7a
[00:12:59] Step 2/18 : COPY scripts/android-base-apt-get.sh /scripts/
---
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=========                              ] 25% Fetch remote repository...        
[=======================================] 100% Fetch remote repository...       
Error: Package path is not valid. Valid system image paths are:
[00:13:08] null
[00:13:09] The command '/bin/sh -c . /scripts/android-sdk.sh &&     download_and_create_avd 4333796 armeabi-v7a 18' returned a non-zero code: 1
travis_time:end:11cc5f7e:start=1548212492434555047,finish=1548213282270481906,duration=789835926859
The command "stamp sh -x -c "$RUN_SCRIPT"" exited with 1.
travis_time:start:089f7ef1
$ date && (curl -fs --head https://google.com | grep ^Date: | sed 's/Date: //g' || true)
---
travis_time:end:0cc10104:start=1548213283286918925,finish=1548213283295958347,duration=9039422
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:0d8b714b
$ 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\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load 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:2b702ce0
travis_time:start:2b702ce0
$ 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:310f71aa
$ 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)

@pietroalbini
Copy link
Member

@bors treeclosed- retry

@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 Jan 23, 2019
@bors
Copy link
Contributor

bors commented Jan 23, 2019

⌛ Testing commit 569fa82 with merge 67de45885c083d83f3c3a952aa57a759e37f8534...

@bors
Copy link
Contributor

bors commented Jan 23, 2019

💔 Test failed - checks-travis

@rust-highfive
Copy link
Collaborator

The job wasm32-unknown 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.
[01:11:10] [RUSTC-TIMING] coretests test:true 94.557
[01:11:10]     Finished release [optimized] target(s) in 1m 42s
[01:11:10]      Running build/x86_64-unknown-linux-gnu/stage2-std/wasm32-unknown-unknown/release/deps/coretests-7f0cbf4f70a8e2de.wasm
[01:11:12] RuntimeError: unreachable
[01:11:12]     at __rust_start_panic (wasm-function[1124]:45)
[01:11:12]     at rust_panic (wasm-function[1111]:39)
[01:11:12]     at _ZN3std9panicking20rust_panic_with_hook17hc2c13f1d99b58d10E (wasm-function[1106]:346)
[01:11:12]     at _ZN3std9panicking18continue_panic_fmt17h80bcb903aad73512E (wasm-function[1105]:151)
[01:11:12]     at _ZN3std9panicking15begin_panic_fmt17hd9bf6ce25f316536E (wasm-function[982]:108)
[01:11:12]     at _ZN39_$LT$R$u20$as$u20$rand..FromEntropy$GT$12from_entropy28_$u7b$$u7b$closure$u7d$$u7d$17h854d3f2a84855e91E (wasm-function[9]:84)
[01:11:12]     at _ZN9coretests5slice18partition_at_index17h13b4889758b2d0b5E (wasm-function[545]:10497)
[01:11:12]     at _ZN4core3ops8function6FnOnce9call_once17hcfce963d06aeb0d6E (wasm-function[544]:21)
[01:11:12]     at _ZN4test28__rust_begin_short_backtrace17h494b34b0b35103f4E (wasm-function[783]:3)
[01:11:12]     at _ZN50_$LT$F$u20$as$u20$alloc..boxed..FnBox$LT$A$GT$$GT$8call_box17h695e58f6fc648d60E (wasm-function[782]:6)
[01:11:12]     at _ZN3std9panicking3try7do_call17hed02831d2b67832cE (wasm-function[709]:14)
[01:11:12]     at __rust_maybe_catch_panic (wasm-function[1123]:5)
[01:11:12]     at _ZN4test8run_test14run_test_inner17h06ba453083ee074cE (wasm-function[864]:801)
[01:11:12]     at _ZN4test8run_test17hbea81826c4538903E (wasm-function[861]:2119)
[01:11:12]     at _ZN4test9run_tests17hfda02b999bc6fba5E (wasm-function[856]:4862)
[01:11:12]     at _ZN4test17run_tests_console17hc45fe3f2218d5807E (wasm-function[850]:993)
[01:11:12]     at _ZN4test9test_main17hc6e84b95e2982be1E (wasm-function[847]:433)
[01:11:12]     at _ZN4test16test_main_static17hfcd7d3e85b15a62bE (wasm-function[851]:1747)
[01:11:12]     at _ZN9coretests4main17h442538944079574cE (wasm-function[653]:10)
[01:11:12]     at _ZN3std2rt10lang_start28_$u7b$$u7b$closure$u7d$$u7d$17hab1980bbadd9a85aE (wasm-function[10]:25)
[01:11:12] 
[01:11:12] 
[01:11:12] 
[01:11:12] command did not execute successfully: "/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo" "test" "--target" "wasm32-unknown-unknown" "-j" "4" "--release" "--locked" "--color" "always" "--features" "panic-unwind backtrace" "--manifest-path" "/checkout/src/libstd/Cargo.toml" "-p" "core" "--"
[01:11:12] 
[01:11:12] 
[01:11:12] failed to run: /checkout/obj/build/bootstrap/debug/bootstrap test --target wasm32-unknown-unknown src/test/run-make src/test/ui src/test/run-pass src/test/compile-fail src/test/mir-opt src/test/codegen-units src/libcore
[01:11:12] Build completed unsuccessfully in 1:08:12
---
travis_time:end:050ce4ba:start=1548274625825578526,finish=1548274625845108104,duration=19529578
travis_fold:end:after_failure.3
travis_fold:start:after_failure.4
travis_time:start:0355f0ca
$ 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\033[31;1m%s\033[0m\n" "$CORE"; gdb --batch -q -c "$CORE" "$EXE" -iex 'set auto-load 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:0f8b7fb4
travis_time:start:0f8b7fb4
$ 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:047216b8
$ 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)

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jan 23, 2019
@Centril Centril closed this Jan 23, 2019
@Centril Centril deleted the rollup branch January 23, 2019 23:12
@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-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants