Uh oh!
There was an error while loading. Please reload this page.
Changed error message E0408 to new format - #36307
Conversation
rust-highfive
commented
Sep 6, 2016
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @jonathandturner (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. |
faebser
commented
Sep 6, 2016
GuillaumeGomez
commented
Sep 7, 2016
Thanks for your PR! You also need to update the corresponding test(s) to reflect your changes. They are located in |
sophiajt
commented
Sep 8, 2016
@faebser - as @GuillaumeGomez mentions, the test infrastructure has some quirks. One is that the labels aren't tested until you add your first NOTE. You can read about this in the Extra Credit part of the blog post |
faebser
commented
Sep 9, 2016
@jonathandturner thanks for the heads up. I will work on the test as soon I have time. |
GuillaumeGomez
commented
Sep 9, 2016
@faebser: Don't worry, we're not in a hurry. Just comment here once done. |
faebser
commented
Sep 22, 2016
@jonathandturner I don't really get where I have to add the note? |
sophiajt
commented
Sep 23, 2016
@faebser - can you add your changes to this PR so we can take a look? |
faebser
commented
Sep 25, 2016
@jonathandturner I added my try as a commit to the PR. failures:
---- [compile-fail] compile-fail/E0408.rs stdout ----
error: /home/faebser/workspace/rust/src/test/compile-fail/E0408.rs:15:unexpected"error":'15:19:15:23: variable `y` from pattern #1 is not bound in pattern #2[E0408]'
error: /home/faebser/workspace/rust/src/test/compile-fail/E0408.rs:15:unexpected"note":'pattern doesn't bind `y`'
error: /home/faebser/workspace/rust/src/test/compile-fail/E0408.rs:14: expected error not found: variable `y` from pattern #2 is not bound in pattern #1
error: /home/faebser/workspace/rust/src/test/compile-fail/E0408.rs:14: expected note not found: pattern doesn't bind `y`
error:2 unexpected errors found,2 expected errors not found
status: exit code:101 |
GuillaumeGomez
commented
Sep 25, 2016
Then fix them? I don't know what to add actually. :-/ |
faebser
commented
Sep 26, 2016
@GuillaumeGomez: I am sorry but I am a bit lost and I don't really understand how to fix this error. I added them to this PR because @jonathandturner asked me to. |
The "errors" you see come from So let's see the first one: It says that an annotation was not found. So let's look to your file: It means you expect an error to be thrown by the line before this one (the "^" says it). Better like this? |
faebser
commented
Sep 26, 2016
@GuillaumeGomez: thanks for your comment. I also realised that #1 and #2 were the wrong way around thus generating the error. |
GuillaumeGomez
left a comment
There was a problem hiding this comment.
Once these fixed, please squash your commits. If you don't know how to do it, take a look here.
There was a problem hiding this comment.
Generally, we use "//|" and not "//^" when it's on the same line. I mean that the note is thrown by the same line than the error, so it's the "same" issue. With this way to write it, we have the feeling that it's two different errors.
Also, can you align "//^ NOTE pattern doesn't bind ERROR variable y" with "//y from pattern #1 is not bound in pattern #2" please?
faebser
commented
Sep 27, 2016
@GuillaumeGomez can you please review the third test too? thanks |
GuillaumeGomez
commented
Sep 28, 2016
All good for me. Please squash your commits now. |
KiChjang
commented
Oct 12, 2016
This looks like it only requires squashing, what's blocking this for 2 weeks? |
GuillaumeGomez
commented
Oct 12, 2016
No clue. :-/ |
caa2204 to
4dde9a5Comparefaebser
commented
Oct 12, 2016
Sorry for the delay, I thought that the squash was okay but after having another look today I saw that it did not work. I am working on fixing it right now. |
4dde9a5 to
595b754Comparefaebser
commented
Oct 12, 2016
@GuillaumeGomez: squash is okay now |
GuillaumeGomez
commented
Oct 13, 2016
Thanks! @bors: r+ rollup |
bors
commented
Oct 13, 2016
📌 Commit 595b754 has been approved by |
bors
commented
Oct 13, 2016
⌛ Testing commit 595b754 with merge c80d21d... |
bors
commented
Oct 13, 2016
💔 Test failed - auto-linux-cross-opt |
arielb1
commented
Oct 13, 2016
@bors retry |
alexcrichton
commented
Oct 13, 2016
@bors: retry |
…uillaumeGomez Changed error message E0408 to new format Followed your text and was able to change the ouput to the new format. I did not encounter any broken test therefore this is a really small commit. Thanks for letting me hack on the compiler :) r? @jonathandturner
Followed your text and was able to change the ouput to the new format.
I did not encounter any broken test therefore this is a really small commit.
Thanks for letting me hack on the compiler :)
r? @jonathandturner