11//! Compiled single-step transforms for the text-processing pipeline.
22//!
3- //! Each [`TransformStep`] variant wraps a low-level matcher (VariantNorm,
4- //! Delete, Normalize, Romanize) and provides a uniform
3+ //! Each [`TransformStep`] variant wraps a low-level matcher (None, VariantNorm,
4+ //! Delete, Normalize, Romanize, RomanizeChar, EmojiNorm ) and provides a uniform
55//! [`apply`](TransformStep::apply) interface. Returns `Option<String>` — `None`
66//! when the input is unaffected.
77//!
@@ -37,7 +37,7 @@ pub(crate) enum TransformStep {
3737 VariantNorm ( VariantNormMatcher ) ,
3838 /// Codepoint deletion using a bitset, with optional SIMD acceleration.
3939 Delete ( DeleteMatcher ) ,
40- /// Multi-character normalization replacements via Aho-Corasick .
40+ /// Multi-character normalization replacements via page-table lookup .
4141 Normalize ( NormalizeMatcher ) ,
4242 /// CJK romanization with inter-syllable spaces preserved.
4343 Romanize ( RomanizeMatcher ) ,
@@ -47,13 +47,14 @@ pub(crate) enum TransformStep {
4747 EmojiNorm ( RomanizeMatcher ) ,
4848}
4949
50- /// Streaming byte iterator wrapping one of the four fusible
51- /// [`FilterIterator`] specializations.
50+ /// Streaming byte iterator wrapping one of the four [`FilterIterator`]
51+ /// specializations (Delete, Normalize, VariantNorm, Romanize) .
5252///
5353/// Returned by [`TransformStep::filter_bytes`] for steps that support the
54- /// fused transform-scan path (Delete, Normalize, VariantNorm, Romanize,
55- /// RomanizeChar). `EmojiNorm` and `None` return `Option::None` from
56- /// `filter_bytes`.
54+ /// fused transform-scan path. Five steps support filtering (Delete,
55+ /// Normalize, VariantNorm, Romanize, RomanizeChar) — RomanizeChar reuses
56+ /// the `Romanize` filter variant. `EmojiNorm` and `None` return
57+ /// `Option::None` from `filter_bytes`.
5758pub ( crate ) enum TransformFilter < ' a > {
5859 Delete ( FilterIterator < ' a , DeleteFilter < ' a > > ) ,
5960 Normalize ( FilterIterator < ' a , NormalizeFilter < ' a > > ) ,
0 commit comments