diff options
author | Lars Wirzenius <liw@liw.fi> | 2019-12-01 10:14:00 +0200 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2019-12-01 10:14:00 +0200 |
commit | 8148a61b2417f71dcceec6798b15848f9a08fce7 (patch) | |
tree | 647549d1f47bed2486f5a569d5c80441937ee5ea /src/typeset.rs | |
parent | 3ccba3039795ce0be3e5f5cec6216dc853da76c2 (diff) | |
download | subplot-8148a61b2417f71dcceec6798b15848f9a08fce7.tar.gz |
Refactor: rustfmt
Diffstat (limited to 'src/typeset.rs')
-rw-r--r-- | src/typeset.rs | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/src/typeset.rs b/src/typeset.rs index 46be484..b2a0758 100644 --- a/src/typeset.rs +++ b/src/typeset.rs @@ -1,10 +1,9 @@ -use pandoc_ast::{Block, Inline}; use crate::parser::parse_scenario_snippet; use crate::Bindings; +use crate::PartialStep; use crate::ScenarioStep; use crate::StepKind; -use crate::PartialStep; - +use pandoc_ast::{Block, Inline}; /// Typeset an error from dot as a Pandoc AST Block element. pub fn error(err: Box<dyn std::error::Error>) -> Block { @@ -19,7 +18,6 @@ pub fn error_msg(msg: &str) -> Vec<Inline> { vec![msg] } - /// Typeset a scenario snippet as a Pandoc AST Block. /// /// The snippet is given as a text string, which is parsed. It need @@ -74,19 +72,16 @@ fn keyword(step: &ScenarioStep) -> Inline { Inline::Emph(vec![word]) } - // Typeset a space between words. fn space() -> Inline { Inline::Space } - // Typeset an uncaptured part of a step. fn uncaptured(s: &str) -> Inline { Inline::Str(s.into()) } - // Typeset a captured part of a step. fn captured(s: &str) -> Inline { let s = Inline::Str(s.into()); |