ParseErrorA
This commit is contained in:
parent
2683f1d5ea
commit
673ab92662
@ -83,6 +83,8 @@ pub type Mtbl<'a, Ctx, F> = <F as Factory<'a, Ctx>>::Mtbl;
|
|||||||
|
|
||||||
pub type ParseError<'a, Ctx, F> = <F as Factory<'a, Ctx>>::ParseError;
|
pub type ParseError<'a, Ctx, F> = <F as Factory<'a, Ctx>>::ParseError;
|
||||||
|
|
||||||
|
pub type ParseErrorA<'a, Ctx, A> = ParseError<'a, Ctx, Fctr<'a, Ctx, A>>;
|
||||||
|
|
||||||
/// Extension trait for factories.
|
/// Extension trait for factories.
|
||||||
pub trait ExtFactory<'a, Ctx: Context<'a>>: Factory<'a, Ctx> {
|
pub trait ExtFactory<'a, Ctx: Context<'a>>: Factory<'a, Ctx> {
|
||||||
/// Parse the object from a slice.
|
/// Parse the object from a slice.
|
||||||
|
@ -20,7 +20,7 @@ impl<L, P> ResolutionError<L, P> {
|
|||||||
|
|
||||||
/// See [`ResolutionResult`].
|
/// See [`ResolutionResult`].
|
||||||
pub type ResolutionFailure<'a, Ctx, A> =
|
pub type ResolutionFailure<'a, Ctx, A> =
|
||||||
ResolutionError<<Ctx as Context<'a>>::LookupError, ParseError<'a, Ctx, Fctr<'a, Ctx, A>>>;
|
ResolutionError<<Ctx as Context<'a>>::LookupError, ParseErrorA<'a, Ctx, A>>;
|
||||||
|
|
||||||
/// Result yielded by [`Origin`].
|
/// Result yielded by [`Origin`].
|
||||||
pub type ResolutionResult<'a, Ctx, A> = Result<Rc<A>, ResolutionFailure<'a, Ctx, A>>;
|
pub type ResolutionResult<'a, Ctx, A> = Result<Rc<A>, ResolutionFailure<'a, Ctx, A>>;
|
||||||
|
@ -149,7 +149,7 @@ where
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// Returned by [`TypelessMentionable::cast`].
|
/// Returned by [`TypelessMentionable::cast`].
|
||||||
pub type CastResult<'a, Ctx, A> = Result<A, ParseError<'a, Ctx, Fctr<'a, Ctx, A>>>;
|
pub type CastResult<'a, Ctx, A> = Result<A, ParseErrorA<'a, Ctx, A>>;
|
||||||
|
|
||||||
impl<'a, Ctx: Context<'a>> TypelessMentionable<'a, Ctx>
|
impl<'a, Ctx: Context<'a>> TypelessMentionable<'a, Ctx>
|
||||||
where
|
where
|
||||||
|
@ -39,7 +39,7 @@ impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>, E: 'a>
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
type TreeParseError2<'a, Ctx, A> = TreeParseError<ParseError<'a, Ctx, Fctr<'a, Ctx, A>>>;
|
type TreeParseError2<'a, Ctx, A> = TreeParseError<ParseErrorA<'a, Ctx, A>>;
|
||||||
|
|
||||||
impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>, E: 'a> From<TreeParseError2<'a, Ctx, A>>
|
impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>, E: 'a> From<TreeParseError2<'a, Ctx, A>>
|
||||||
for TreeContextError<'a, Ctx, A, E>
|
for TreeContextError<'a, Ctx, A, E>
|
||||||
|
Loading…
Reference in New Issue
Block a user