Closed
Description
e.g.
trait Foo {}
trait Bar {}
type Alias = Foo + Bar;
// typechecks fine:
fn bar<T: Foo + Bar>(t: T) {
baz(t)
}
fn baz<T: Alias>(t: T) {
bar(t)
}
This is similar to defining a trait inheriting from both (trait Alias: Foo + Bar {}
) but it's purely a synonym and doesn't have to be impl
'd separately.