INNER CODE UNIT · Rust
from
bminixhofer/nlprule · python/src/lib.rs:394
fn from(tokenizer: Tokenizer) -> Self {
PyTokenizer { tokenizer }
}
}
/// An example associated with a grammatical rule.
///
/// Attributes:
/// * text (str): the text of this example
/// * suggestion (Option[Suggestion]): The suggestion for this example.
/// If this is None, it is an example of where the rule should not trigger.
#[pyclass(name = "Example", module = "nlprule")]
struct PyExample {
text: String,
suggestion: Option<Py<PySuggestion>>,
}
impl PyExample {