diff options
author | René Kijewski <rene.kijewski@fu-berlin.de> | 2023-02-20 11:46:41 +0100 |
---|---|---|
committer | Dirkjan Ochtman <dirkjan@ochtman.nl> | 2023-02-21 13:16:00 +0100 |
commit | 70c5784a9ebc1e2f9e97d5358c7b686111ea18f4 (patch) | |
tree | 2983982f8a6feaaae9fa5aef0ed3235c981563b4 /askama_derive/src/input.rs | |
parent | 9f3325cbe7901e7d2350c1554029ccaf5ff61621 (diff) | |
download | askama-70c5784a9ebc1e2f9e97d5358c7b686111ea18f4.tar.gz askama-70c5784a9ebc1e2f9e97d5358c7b686111ea18f4.tar.bz2 askama-70c5784a9ebc1e2f9e97d5358c7b686111ea18f4.zip |
Revert "derive: Make Config `'static`"
Diffstat (limited to 'askama_derive/src/input.rs')
-rw-r--r-- | askama_derive/src/input.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/askama_derive/src/input.rs b/askama_derive/src/input.rs index b8a0da4..47d51bd 100644 --- a/askama_derive/src/input.rs +++ b/askama_derive/src/input.rs @@ -9,8 +9,8 @@ use mime::Mime; pub(crate) struct TemplateInput<'a> { pub(crate) ast: &'a syn::DeriveInput, - pub(crate) config: &'a Config, - pub(crate) syntax: &'a Syntax, + pub(crate) config: &'a Config<'a>, + pub(crate) syntax: &'a Syntax<'a>, pub(crate) source: Source, pub(crate) print: Print, pub(crate) escaper: &'a str, @@ -25,7 +25,7 @@ impl TemplateInput<'_> { /// `template()` attribute list fields. pub(crate) fn new<'n>( ast: &'n syn::DeriveInput, - config: &'n Config, + config: &'n Config<'_>, args: TemplateArgs, ) -> Result<TemplateInput<'n>, CompileError> { let TemplateArgs { @@ -51,7 +51,7 @@ impl TemplateInput<'_> { // Validate syntax let syntax = syntax.map_or_else( - || Ok(config.syntaxes.get(&config.default_syntax).unwrap()), + || Ok(config.syntaxes.get(config.default_syntax).unwrap()), |s| { config .syntaxes |