]> git.lizzy.rs Git - rust.git/blob - tests/ui/type-alias-impl-trait/type-alias-impl-trait-fn-type.rs
Rollup merge of #104965 - zacklukem:p-option-as_ref-docs, r=scottmcm
[rust.git] / tests / ui / type-alias-impl-trait / type-alias-impl-trait-fn-type.rs
1 #![feature(type_alias_impl_trait)]
2 #![allow(dead_code)]
3
4 // FIXME: this is ruled out for now but should work
5
6 type Foo = fn() -> impl Send;
7 //~^ ERROR: `impl Trait` only allowed in function and inherent method return types
8
9 fn make_foo() -> Foo {
10     || 15
11 }
12
13 fn main() {}