Diffstat (limited to 'src/protocol/visitor/sequence.rs')
-rw-r--r--src/protocol/visitor/sequence.rs16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/protocol/visitor/sequence.rs b/src/protocol/visitor/sequence.rs
index 8c7b2e4..d313e5b 100644
--- a/src/protocol/visitor/sequence.rs
+++ b/src/protocol/visitor/sequence.rs
@@ -38,22 +38,22 @@ pub trait SequenceScope<'ctx, E: Effect<'ctx>> {
pub type DynSequenceScope<'a, 'ctx, E> = &'a mut (dyn SequenceScope<'ctx, E> + Send + 'a);
higher_ranked_type! {
- pub type KnownHkt['ctx]: (AnySend) = for<'lt> Known
+ pub type SequenceKnownHkt['ctx]: (AnySend) = for<'lt> SequenceKnown
}
#[derive(Default)]
-pub struct Known {
+pub struct SequenceKnown {
pub len: (usize, Option<usize>),
}
-pub struct Hint {
+pub struct SequenceHint {
pub len: (usize, Option<usize>),
}
impl<'a, 'ctx: 'a, E: Effect<'ctx>> HintMeta<'ctx> for DynSequence<'a, 'ctx, E> {
- type Known = KnownHkt<'ctx>;
+ type Known = SequenceKnownHkt<'ctx>;
- type Hint = Hint;
+ type Hint = SequenceHint;
}
pub fn visit_sequence<'a, 'ctx, E: Effect<'ctx>>(
@@ -66,16 +66,16 @@ pub fn visit_sequence<'a, 'ctx, E: Effect<'ctx>>(
Flow::Continue => {
// The visitor wants the walker to continue to it's normal
// walking.
- Status::Continue
+ Status::r#continue()
}
Flow::Break | Flow::Done => {
// The visitor is done (either because of an error or because
// it already used a hint).
- Status::Break
+ Status::r#break()
}
})
} else {
// If the visitor doesn't support request hint then we continue.
- E::ready(Status::Skipped)
+ E::ready(Status::skipped())
}
}