Skip to content

Stack overflow when using inline partial #697

@JWo1F

Description

@JWo1F

Hey, everybody!

When using regular partials, as well as inline partials, I get a “stack overflow” error, although nesting is obviously limited. This is probably some internal bug.

fn test_hs() {
  let mut hs = Handlebars::new();
  hs.register_template_string("primary", "{{> @partial-block }}").unwrap();
  hs.register_template_string("secondary", "{{#*inline \"inl\"}}Bug{{/inline}}{{#>primary}}{{>inl}}{{> @partial-block }}{{/primary}}").unwrap();
  hs.register_template_string("current", "{{>secondary}}").unwrap();

  hs.render("current", &()).unwrap();
}

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions