mirror of
https://github.com/askama-rs/askama.git
synced 2026-03-23 10:15:14 +00:00
* Parsing function calls is expensive. Make sure not to stack overflow. * We only need to to call `level.nest()` if we descent, but we need to call it before we descent.
52 lines
1.2 KiB
Rust
52 lines
1.2 KiB
Rust
use askama::Template;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call( }}"#)]
|
|
struct UnclosedCall1;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a }}"#)]
|
|
struct UnclosedCall2;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a, }}"#)]
|
|
struct UnclosedCall3;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a, b }}"#)]
|
|
struct UnclosedCall4;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a, b, }}"#)]
|
|
struct UnclosedCall5;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(,) }}"#)]
|
|
struct CommaWithoutAnyArguments1;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(, a) }}"#)]
|
|
struct CommaWithoutAnyArguments2;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(, a,) }}"#)]
|
|
struct CommaWithoutAnyArguments3;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(, a, }}"#)]
|
|
struct CommaWithoutAnyArguments4;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a,,) }}"#)]
|
|
struct MultipleCommas1;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a,, b,) }}"#)]
|
|
struct MultipleCommas2;
|
|
|
|
#[derive(Template)]
|
|
#[template(ext = "txt", source = r#"{{ call(a, b,,) }}"#)]
|
|
struct MultipleCommas3;
|
|
|
|
fn main() {}
|