2021-07-26 17:01:16 -03:00
|
|
|
#![feature(type_alias_impl_trait)]
|
2020-07-03 18:41:23 -04:00
|
|
|
|
|
|
|
trait MyTrait {}
|
|
|
|
impl MyTrait for i32 {}
|
|
|
|
|
2022-08-10 13:13:18 -07:00
|
|
|
// @hasraw impl_trait_alias/type.Foo.html 'Foo'
|
2020-07-03 18:41:23 -04:00
|
|
|
/// debug type
|
|
|
|
pub type Foo = impl MyTrait;
|
|
|
|
|
2022-08-10 13:13:18 -07:00
|
|
|
// @hasraw impl_trait_alias/fn.foo.html 'foo'
|
2020-07-03 18:41:23 -04:00
|
|
|
/// debug function
|
|
|
|
pub fn foo() -> Foo {
|
|
|
|
1
|
|
|
|
}
|