From 9aa40569b4a2dc76474d3e4d220afc12b065b511 Mon Sep 17 00:00:00 2001 From: Dirkjan Ochtman Date: Sun, 17 Feb 2019 20:56:31 +0100 Subject: Fix formatting for 1.32.0 --- askama/src/lib.rs | 5 ++++- askama_derive/src/generator.rs | 18 ++++++++++++------ 2 files changed, 16 insertions(+), 7 deletions(-) diff --git a/askama/src/lib.rs b/askama/src/lib.rs index d643c18..a0d641b 100644 --- a/askama/src/lib.rs +++ b/askama/src/lib.rs @@ -522,5 +522,8 @@ pub mod gotham { /// Old build script helper to rebuild crates if contained templates have changed /// /// This function is now deprecated and does nothing. -#[deprecated(since="0.8.1", note="file-level dependency tracking is handled automatically without build script")] +#[deprecated( + since = "0.8.1", + note = "file-level dependency tracking is handled automatically without build script" +)] pub fn rerun_if_templates_changed() {} diff --git a/askama_derive/src/generator.rs b/askama_derive/src/generator.rs index 7db4a49..b0630df 100644 --- a/askama_derive/src/generator.rs +++ b/askama_derive/src/generator.rs @@ -117,9 +117,12 @@ impl<'a> Generator<'a> { }; if path_is_valid { let path = path.to_str().unwrap(); - buf.writeln("e! { - include_bytes!(#path); - }.to_string()); + buf.writeln( + "e! { + include_bytes!(#path); + } + .to_string(), + ); } } @@ -624,9 +627,12 @@ impl<'a> Generator<'a> { // Make sure the compiler understands that the generated code depends on the template file. { let path = path.to_str().unwrap(); - buf.writeln("e! { - include_bytes!(#path); - }.to_string()); + buf.writeln( + "e! { + include_bytes!(#path); + } + .to_string(), + ); } let size_hint = { -- cgit