fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1warning: function cannot return without recursing 2 --> $DIR/recursive.rs:3:1 3 | 4LL | const fn f<T>(x: T) { 5 | ^^^^^^^^^^^^^^^^^^^ cannot return without recursing 6LL | f(x); 7 | ---- recursive call site 8 | 9 = help: a `loop` may express intention better if this is on purpose 10 = note: `#[warn(unconditional_recursion)]` on by default 11 12error[E0080]: evaluation of constant value failed 13 --> $DIR/recursive.rs:4:5 14 | 15LL | f(x); 16 | ^^^^ reached the configured maximum number of stack frames 17 | 18note: inside `f::<i32>` 19 --> $DIR/recursive.rs:4:5 20 | 21LL | f(x); 22 | ^^^^ 23note: [... 126 additional calls inside `f::<i32>` ...] 24 --> $DIR/recursive.rs:4:5 25 | 26LL | f(x); 27 | ^^^^ 28note: inside `X` 29 --> $DIR/recursive.rs:8:15 30 | 31LL | const X: () = f(1); 32 | ^^^^ 33 34error: aborting due to previous error; 1 warning emitted 35 36For more information about this error, try `rustc --explain E0080`.