aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2018-09-07 20:09:47 +0200
committerLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2018-09-07 20:09:47 +0200
commitd4671611597837dec3108f3a7f3af46be1bc4c36 (patch)
treedcd431da0f6840a824290199d875148b76611da4
parent4f2176a3ad2d174c40617c9f3af13b6bd8270b29 (diff)
downloadaskama-d4671611597837dec3108f3a7f3af46be1bc4c36.tar.gz
askama-d4671611597837dec3108f3a7f3af46be1bc4c36.tar.bz2
askama-d4671611597837dec3108f3a7f3af46be1bc4c36.zip
Fix formatting with cargo fmt
-rw-r--r--askama_derive/src/generator.rs21
1 files changed, 12 insertions, 9 deletions
diff --git a/askama_derive/src/generator.rs b/askama_derive/src/generator.rs
index 07a90e5..5a136fb 100644
--- a/askama_derive/src/generator.rs
+++ b/askama_derive/src/generator.rs
@@ -435,18 +435,21 @@ impl<'a> Generator<'a> {
.contexts
.get(path)
.unwrap_or_else(|| panic!("context for '{:?}' not found", path));
- (mctx.macros
- .get(name)
- .unwrap_or_else(|| panic!("macro '{}' not found in scope '{}'", s, name)),
- mctx)
+ (
+ mctx.macros
+ .get(name)
+ .unwrap_or_else(|| panic!("macro '{}' not found in scope '{}'", s, name)),
+ mctx,
+ )
} else {
- (ctx.macros
- .get(name)
- .unwrap_or_else(|| panic!("macro '{}' not found", name)),
- ctx)
+ (
+ ctx.macros
+ .get(name)
+ .unwrap_or_else(|| panic!("macro '{}' not found", name)),
+ ctx,
+ )
};
-
self.flush_ws(buf, ws); // Cannot handle_ws() here: whitespace from macro definition comes first
self.locals.push();
buf.writeln("{");