]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/associated-const/associated-const-no-item.stderr
keep predicate order and tweak output
[rust.git] / src / test / ui / associated-const / associated-const-no-item.stderr
index c3339e453e81e63cace37baad431ca0167a7192f..fe27da5ac645f5329c2cbaaae1cb6e66090adf6b 100644 (file)
@@ -1,13 +1,15 @@
 error[E0599]: no associated item named `ID` found for type `i32` in the current scope
   --> $DIR/associated-const-no-item.rs:5:23
    |
-LL | trait Foo {
-   | --------- `Foo` defines an item `ID`, perhaps you need to implement it
-...
 LL | const X: i32 = <i32>::ID;
    |                       ^^ associated item not found in `i32`
    |
    = help: items from traits can only be used if the trait is implemented and in scope
+note: `Foo` defines an item `ID`, perhaps you need to implement it
+  --> $DIR/associated-const-no-item.rs:1:1
+   |
+LL | trait Foo {
+   | ^^^^^^^^^
 
 error: aborting due to previous error