Code structure for latex environment.
This commit is contained in:
@@ -89,6 +89,11 @@ pub struct Keyword<'s> {
|
||||
pub source: &'s str,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
pub struct LatexEnvironment<'s> {
|
||||
pub source: &'s str,
|
||||
}
|
||||
|
||||
impl<'s> Paragraph<'s> {
|
||||
pub fn of_text(input: &'s str) -> Self {
|
||||
let mut objects = Vec::with_capacity(1);
|
||||
@@ -179,3 +184,9 @@ impl<'s> Source<'s> for Keyword<'s> {
|
||||
self.source
|
||||
}
|
||||
}
|
||||
|
||||
impl<'s> Source<'s> for LatexEnvironment<'s> {
|
||||
fn get_source(&'s self) -> &'s str {
|
||||
self.source
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user