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 29, 2016
1 parent 36656f8 commit efe56c8
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
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() {}
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
}
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
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
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
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
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
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
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
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
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 efe56c8

Please sign in to comment.