]>
git.proxmox.com Git - rustc.git/blob - src/test/ui/associated-types/normalization-generality.rs
3 // Ensures that we don't regress on "implementation is not general enough" when
4 // normalizating under binders.
8 pub trait Yokeable
<'a
> {
12 pub struct Yoke
<Y
: for<'a
> Yokeable
<'a
>> {
16 impl<Y
: for<'a
> Yokeable
<'a
>> Yoke
<Y
> {
17 pub fn project
<'this
, P
>(
19 _f
: for<'a
> fn(<Y
as Yokeable
<'a
>>::Output
, &'
a ()) -> <P
as Yokeable
<'a
>>::Output
,
22 P
: for<'a
> Yokeable
<'a
>,
28 pub fn slice(y
: Yoke
<&'
static ()>) -> Yoke
<&'
static ()> {
29 y
.project(move |yk
, _
| yk
)
32 impl<'a
, T
> Yokeable
<'a
> for &'
static T
{