Uh oh!
There was an error while loading. Please reload this page.
regression tests for ICEs - #42230
Conversation
rust-highfive
commented
May 25, 2017
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @Mark-Simulacrum (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
There was a problem hiding this comment.
I believe this test needs to have --unpretty mir -Z unstable-options passed to the compiler. // compile-flags: -Z unstable-options --unpretty=mir should work at the top of the file.
There was a problem hiding this comment.
Hm, looks like this won't quite work since (I believe) we don't actually reach the phase of the compiler where this errors out. Could you add a let x: () = 0; line with //~ ERROR: mismatched types attached to it and remove the rustc_error?
There was a problem hiding this comment.
Thanks for the tip. Am getting the error locally now, with & without the mir option.
Have pushed the fix.
e1b59c6 to
c4570a7CompareMark-Simulacrum
commented
May 25, 2017
Thanks! @bors r+ rollup |
bors
commented
May 25, 2017
📌 Commit c4570a7 has been approved by |
Mark-Simulacrum
commented
May 25, 2017
@bors r- Travis failed |
venkatagiri
commented
May 26, 2017
The $ build/x86_64-unknown-linux-gnu/stage2/bin/rustc src/test/compile-fail/issue-37665.rs \
-L build/x86_64-unknown-linux-gnu/test/compile-fail --target=x86_64-unknown-linux-gnu --error-format json \
-L build/x86_64-unknown-linux-gnu/test/compile-fail/issue-37665.stage2-x86_64-unknown-linux-gnu.compile-fail.libaux \
-C prefer-dynamic -o build/x86_64-unknown-linux-gnu/test/compile-fail/issue-37665.stage2-x86_64-unknown-linux-gnu \
-Crpath -O -Lnative=build/x86_64-unknown-linux-gnu/native/rust-test-helpers -Z unstable-options --unpretty=mir
$ echo$?
0
$ build/x86_64-unknown-linux-gnu/stage2/bin/rustc src/test/compile-fail/issue-37665.rs \
-L build/x86_64-unknown-linux-gnu/test/compile-fail --target=x86_64-unknown-linux-gnu --error-format json \
-L build/x86_64-unknown-linux-gnu/test/compile-fail/issue-37665.stage2-x86_64-unknown-linux-gnu.compile-fail.libaux \
-C prefer-dynamic -o build/x86_64-unknown-linux-gnu/test/compile-fail/issue-37665.stage2-x86_64-unknown-linux-gnu \
-Crpath -O -Lnative=build/x86_64-unknown-linux-gnu/native/rust-test-helpers -Z unstable-options
{"message":"compilation successful","code":null,"level":"error","spans":[{"file_name":"src/test/compile-fail/issue-37665.rs","byte_start":594,"byte_end":743,"line_start":18,"line_end":22,"column_start":1,"column_end":2,"is_primary":true,"text":[{"text":"fn main() { //~ ERROR compilation successful","highlight_start":1,"highlight_end":45},{"text":" let mut foo : String = \"hello\".to_string();","highlight_start":1,"highlight_end":48},{"text":" foo.push(MAIN_SEPARATOR);","highlight_start":1,"highlight_end":30},{"text":" println!(\"{}\", foo);","highlight_start":1,"highlight_end":25},{"text":"}","highlight_start":1,"highlight_end":2}],"label":null,"suggested_replacement":null,"expansion":null}],"children":[],"rendered":null}
$ echo$?
101 |
Mark-Simulacrum
commented
May 26, 2017
Right, I think the fix I suggested here: #42230 (comment) should help. |
c4570a7 to
2160b4aCompareMark-Simulacrum
commented
May 26, 2017
@bors r+ rollup |
bors
commented
May 26, 2017
📌 Commit 2160b4a has been approved by |
…=Mark-Simulacrum regression tests for ICEs closesrust-lang#36379closesrust-lang#37550closesrust-lang#37665closesrust-lang#38160closesrust-lang#38954closesrust-lang#39362 r? @Mark-Simulacrum
…=Mark-Simulacrum regression tests for ICEs closesrust-lang#36379closesrust-lang#37550closesrust-lang#37665closesrust-lang#38160closesrust-lang#38954closesrust-lang#39362 r? @Mark-Simulacrum
…=Mark-Simulacrum regression tests for ICEs closesrust-lang#36379closesrust-lang#37550closesrust-lang#37665closesrust-lang#38160closesrust-lang#38954closesrust-lang#39362 r? @Mark-Simulacrum
closes#36379
closes#37550
closes#37665
closes#38160
closes#38954
closes#39362
r? @Mark-Simulacrum