about summary refs log tree commit diff
path: root/tests/ui/inline-const/referencing-local-variables.stderr
blob: 7e1cecdddcba6ed0405d2082c38a82c07e7e8af8 (plain)
1
2
3
4
5
6
7
8
9
10
11
error[E0435]: attempt to use a non-constant value in a constant
  --> $DIR/referencing-local-variables.rs:2:13
   |
LL | const fn test_me<T>(a: usize) -> usize {
   |                     - this would need to be a `const`
LL |     const { a }
   |             ^

error: aborting due to 1 previous error

For more information about this error, try `rustc --explain E0435`.