2022-01-14 00:00:00 +00:00
|
|
|
warning: function cannot return without recursing
|
2025-02-11 20:38:58 +08:00
|
|
|
--> $DIR/issue-83150.rs:10:1
|
2022-01-14 00:00:00 +00:00
|
|
|
|
|
|
|
|
|
LL | fn func<T: Iterator<Item = u8>>(iter: &mut T) {
|
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ cannot return without recursing
|
2024-05-24 14:09:40 -04:00
|
|
|
LL |
|
2022-01-14 00:00:00 +00:00
|
|
|
LL | func(&mut iter.map(|x| x + 1))
|
|
|
|
|
| ------------------------------ recursive call site
|
|
|
|
|
|
|
|
|
|
|
= help: a `loop` may express intention better if this is on purpose
|
2022-09-18 19:55:36 +04:00
|
|
|
= note: `#[warn(unconditional_recursion)]` on by default
|
2022-01-14 00:00:00 +00:00
|
|
|
|
2025-02-11 20:38:58 +08:00
|
|
|
error[E0275]: overflow evaluating the requirement `Map<&mut std::ops::Range<u8>, {closure@$DIR/issue-83150.rs:12:24: 12:27}>: Iterator`
|
2021-03-23 12:41:26 +01:00
|
|
|
|
|
2024-07-12 21:15:25 -04:00
|
|
|
= help: consider increasing the recursion limit by adding a `#![recursion_limit = "256"]` attribute to your crate (`issue_83150`)
|
2025-07-16 19:45:07 +00:00
|
|
|
= note: required for `&mut Map<&mut Range<u8>, {closure@issue-83150.rs:12:24}>` to implement `Iterator`
|
2024-07-12 21:15:25 -04:00
|
|
|
= note: 65 redundant requirements hidden
|
2025-07-16 19:45:07 +00:00
|
|
|
= note: required for `&mut Map<&mut Map<&mut Map<&mut Map<&mut ..., ...>, ...>, ...>, ...>` to implement `Iterator`
|
|
|
|
|
= note: the full name for the type has been written to '$TEST_BUILD_DIR/issue-83150.long-type-$LONG_TYPE_HASH.txt'
|
|
|
|
|
= note: consider using `--verbose` to print the full type name to the console
|
2021-03-23 12:41:26 +01:00
|
|
|
|
2023-11-21 15:44:16 +00:00
|
|
|
error: aborting due to 1 previous error; 1 warning emitted
|
2021-03-23 12:41:26 +01:00
|
|
|
|
2024-07-12 21:15:25 -04:00
|
|
|
For more information about this error, try `rustc --explain E0275`.
|