StackCompatibleProxy::T
This commit is contained in:
parent
7253b2402e
commit
2e73ca8c50
@ -39,28 +39,32 @@ pub trait StackCompatible<'a, Ctx: Context<'a>>: Mentionable<'a, Ctx> {
|
|||||||
fn points_typed_rest(stack: &Stack<'a, Ctx, Self>, points: &mut impl PointsVisitor<'a, Ctx>);
|
fn points_typed_rest(stack: &Stack<'a, Ctx, Self>, points: &mut impl PointsVisitor<'a, Ctx>);
|
||||||
}
|
}
|
||||||
|
|
||||||
pub trait StackCompatibleProxy<'a, Ctx: Context<'a>, T>: FactoryProxy<'a, Ctx>
|
pub trait StackCompatibleProxy<'a, Ctx: Context<'a>>: FactoryProxy<'a, Ctx>
|
||||||
where
|
where
|
||||||
Self::F: Factory<'a, Ctx>,
|
Self::F: Factory<'a, Ctx>,
|
||||||
{
|
{
|
||||||
fn points_typed_rest(stack: &T, points: &mut impl PointsVisitor<'a, Ctx>);
|
type T;
|
||||||
|
|
||||||
|
fn points_typed_rest(stack: &Self::T, points: &mut impl PointsVisitor<'a, Ctx>);
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>> StackCompatible<'a, Ctx> for A
|
impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>> StackCompatible<'a, Ctx> for A
|
||||||
where
|
where
|
||||||
<Fctr<'a, Ctx, A> as WithParseMode>::WithMode:
|
<Fctr<'a, Ctx, A> as WithParseMode>::WithMode:
|
||||||
StackCompatibleProxy<'a, Ctx, Stack<'a, Ctx, A>, F = Fctr<'a, Ctx, A>>,
|
StackCompatibleProxy<'a, Ctx, T = Stack<'a, Ctx, A>, F = Fctr<'a, Ctx, A>>,
|
||||||
{
|
{
|
||||||
fn points_typed_rest(stack: &Stack<'a, Ctx, Self>, points: &mut impl PointsVisitor<'a, Ctx>) {
|
fn points_typed_rest(stack: &Stack<'a, Ctx, Self>, points: &mut impl PointsVisitor<'a, Ctx>) {
|
||||||
<<Fctr<'a, Ctx, A> as WithParseMode>::WithMode as StackCompatibleProxy<'a, Ctx, _>>::points_typed_rest(stack, points)
|
<<Fctr<'a, Ctx, A> as WithParseMode>::WithMode as StackCompatibleProxy<'a, Ctx>>::points_typed_rest(stack, points)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a, Ctx: Context<'a>, F: RegularFactory<'a, Ctx>>
|
impl<'a, Ctx: Context<'a>, F: RegularFactory<'a, Ctx>> StackCompatibleProxy<'a, Ctx>
|
||||||
StackCompatibleProxy<'a, Ctx, Stack<'a, Ctx, Mtbl<'a, Ctx, F>>> for WithMode<F, RegularMode>
|
for WithMode<F, RegularMode>
|
||||||
where
|
where
|
||||||
F::Mtbl: MentionableTop<'a, Ctx>,
|
F::Mtbl: MentionableTop<'a, Ctx>,
|
||||||
{
|
{
|
||||||
|
type T = Stack<'a, Ctx, Mtbl<'a, Ctx, F>>;
|
||||||
|
|
||||||
fn points_typed_rest(
|
fn points_typed_rest(
|
||||||
stack: &Stack<'a, Ctx, Mtbl<'a, Ctx, Self::F>>,
|
stack: &Stack<'a, Ctx, Mtbl<'a, Ctx, Self::F>>,
|
||||||
points: &mut impl PointsVisitor<'a, Ctx>,
|
points: &mut impl PointsVisitor<'a, Ctx>,
|
||||||
@ -69,11 +73,13 @@ where
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a, Ctx: Context<'a>, F: InlineableFactory<'a, Ctx>>
|
impl<'a, Ctx: Context<'a>, F: InlineableFactory<'a, Ctx>> StackCompatibleProxy<'a, Ctx>
|
||||||
StackCompatibleProxy<'a, Ctx, Stack<'a, Ctx, Mtbl<'a, Ctx, F>>> for WithMode<F, InliningMode>
|
for WithMode<F, InliningMode>
|
||||||
where
|
where
|
||||||
F::Mtbl: MentionableTop<'a, Ctx>,
|
F::Mtbl: MentionableTop<'a, Ctx>,
|
||||||
{
|
{
|
||||||
|
type T = Stack<'a, Ctx, Mtbl<'a, Ctx, F>>;
|
||||||
|
|
||||||
fn points_typed_rest(
|
fn points_typed_rest(
|
||||||
stack: &Stack<'a, Ctx, Mtbl<'a, Ctx, Self::F>>,
|
stack: &Stack<'a, Ctx, Mtbl<'a, Ctx, Self::F>>,
|
||||||
points: &mut impl PointsVisitor<'a, Ctx>,
|
points: &mut impl PointsVisitor<'a, Ctx>,
|
||||||
|
Loading…
Reference in New Issue
Block a user