2021-07-22 13:16:33 -05:00
|
|
|
static x: impl Fn(&str) -> Result<&str, ()> = move |source| {
|
2022-02-17 21:18:42 -06:00
|
|
|
//~^ `impl Trait` only allowed in function and inherent method return types
|
2021-07-22 13:16:33 -05:00
|
|
|
let res = (move |source| Ok(source))(source);
|
|
|
|
let res = res.or((move |source| Ok(source))(source));
|
|
|
|
res
|
|
|
|
};
|
|
|
|
|
|
|
|
fn main() {}
|