]> git.proxmox.com Git - rustc.git/blame - tests/rustdoc-ui/normalize-cycle.rs
New upstream version 1.73.0+dfsg1
[rustc.git] / tests / rustdoc-ui / normalize-cycle.rs
CommitLineData
a2a8927a 1// check-pass
2b03887a 2// compile-flags: -Znormalize-docs
f2b60f7d 3// Regression test for <https://github.com/rust-lang/rust/issues/79459>.
a2a8927a
XL
4pub trait Query {}
5
6pub trait AsQuery {
7 type Query;
8}
9
10impl<T: Query> AsQuery for T {
11 type Query = T;
12}
13
14pub trait SelectDsl<Selection> {
15 type Output;
16}
17
18impl<T, Selection> SelectDsl<Selection> for T
19where
20 T: AsQuery,
21 T::Query: SelectDsl<Selection>,
22{
23 type Output = <T::Query as SelectDsl<Selection>>::Output;
24}
25
26pub type Select<Source, Selection> = <Source as SelectDsl<Selection>>::Output;