Skip to content

Commit

Permalink
Add missings NOTE and HELP annotations to tests
Browse files Browse the repository at this point in the history
  • Loading branch information
fhahn committed Jan 15, 2016
1 parent 722723d commit 08c590f
Show file tree
Hide file tree
Showing 11 changed files with 32 additions and 9 deletions.
4 changes: 3 additions & 1 deletion src/test/compile-fail/changing-crates.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {}
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,5 @@ fn main() {
meh(foo);
//~^ ERROR: mismatched types:
//~| NOTE: conflicting type parameter defaults `bool` and `char`
//~| NOTE: ...that was applied to an unconstrained type variable here
}
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@ struct Baz<'x> {

impl<'a> Baz<'a> {
fn baz2<'b>(&self, x: &isize) -> (&'b isize, &'b isize) {
//~^ HELP: parameter as shown: fn baz2<'b>(&self, x: &'b isize) -> (&'a isize, &'a isize)
// The lifetime that gets assigned to `x` seems somewhat random.
// I have disabled this test for the time being. --pcwalton
(self.bar, x) //~ ERROR: cannot infer
Expand Down
7 changes: 6 additions & 1 deletion src/test/compile-fail/privacy1.rs
Original file line number Diff line number Diff line change
Expand Up @@ -129,12 +129,17 @@ mod foo {
::bar::baz::foo(); //~ ERROR: function `foo` is inaccessible
//~^ NOTE: module `baz` is private
::bar::baz::bar(); //~ ERROR: function `bar` is inaccessible
//~^ NOTE: module `baz` is private
}

fn test2() {
use bar::baz::{foo, bar};
//~^ ERROR: function `foo` is inaccessible
//~^^ ERROR: function `bar` is inaccessible
//~| NOTE: module `baz` is private
//~| ERROR: function `bar` is inaccessible
//~| NOTE: module `baz` is private


foo();
bar();
}
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-lit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-significant-cfg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-trait-bound.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-type-arg.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-type-ret.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-change-type-static.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,9 @@

extern crate a;
extern crate b; //~ ERROR: found possibly newer version of crate `a` which `b` depends on
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled
//~| NOTE: crate `a` path #1:
//~| NOTE: crate `b` path #1:

fn main() {
b::foo()
Expand Down
4 changes: 3 additions & 1 deletion src/test/compile-fail/svh-use-trait.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@

extern crate uta;
extern crate utb; //~ ERROR: found possibly newer version of crate `uta` which `utb` depends
//~^ NOTE: perhaps this crate needs to be recompiled
//~| NOTE: perhaps this crate needs to be recompiled?
//~| NOTE: crate `uta` path #1:
//~| NOTE: crate `utb` path #1:

fn main() {
utb::foo()
Expand Down

0 comments on commit 08c590f

Please sign in to comment.