2021-07-22 19:16:33 +01:00
|
|
|
static x: impl Fn(&str) -> Result<&str, ()> = move |source| {
|
2023-10-04 19:51:43 +00:00
|
|
|
//~^ `impl Trait` only allowed in function and inherent method argument and return types
|
2021-07-22 19:16:33 +01:00
|
|
|
let res = (move |source| Ok(source))(source);
|
|
|
|
let res = res.or((move |source| Ok(source))(source));
|
|
|
|
res
|
|
|
|
};
|
|
|
|
|
|
|
|
fn main() {}
|