changeset 86:5cfe3b610647

cargo fmt
author Lewin Bormann <lbo@spheniscida.de>
date Wed, 21 Oct 2020 11:57:10 +0200
parents 6884447928d4
children d111720bc9ef
files src/lib.rs src/state.rs
diffstat 2 files changed, 4 insertions(+), 4 deletions(-) [+]
line wrap: on
line diff
--- a/src/lib.rs	Sun Mar 22 16:31:23 2020 +0100
+++ b/src/lib.rs	Wed Oct 21 11:57:10 2020 +0200
@@ -53,9 +53,9 @@
 /// Optimize and compile a regular expression into a representation that can be directly used for
 /// matching with `match_re()`.
 pub fn compile(re: &str) -> Result<state::CompiledRE, String> {
-    Ok(state::CompiledRE(compile::start_compile(&repr::optimize::optimize(parse(
-        re,
-    )?))))
+    Ok(state::CompiledRE(compile::start_compile(
+        &repr::optimize::optimize(parse(re)?),
+    )))
 }
 
 /// Match a regular expression compiled with `compile()` against a string. Returns a tuple of a
--- a/src/state.rs	Sun Mar 22 16:31:23 2020 +0100
+++ b/src/state.rs	Wed Oct 21 11:57:10 2020 +0200
@@ -21,7 +21,7 @@
 pub type StateRef = usize;
 
 /// CompiledRE is a compiled regular expression that can be used for matching.
-pub struct CompiledRE (pub(crate) StateGraph);
+pub struct CompiledRE(pub(crate) StateGraph);
 
 /// State is a single state that the evaluation can be in. It contains several output states as
 /// well as a matcher.