]> git.lizzy.rs Git - rust.git/blobdiff - src/test/ui/error-codes/E0282.stderr
Rollup merge of #98617 - ChrisDenton:const-unwrap, r=Mark-Simulacrum
[rust.git] / src / test / ui / error-codes / E0282.stderr
index 0f610a5e42f65060ad380ad2161ce35d80825e49..d01aa3617c764c1fe9f0c95b65a69bf689c59dc1 100644 (file)
@@ -2,7 +2,12 @@ error[E0282]: type annotations needed
   --> $DIR/E0282.rs:2:9
    |
 LL |     let x = "hello".chars().rev().collect();
-   |         ^ consider giving `x` a type
+   |         ^
+   |
+help: consider giving `x` an explicit type
+   |
+LL |     let x: _ = "hello".chars().rev().collect();
+   |          +++
 
 error: aborting due to previous error