Skip to content

Commit

Permalink
Merge pull request #513 from erikaldsund/cpp11_ambiguity_fix
Browse files Browse the repository at this point in the history
Fix compilation error: ambiguous overload
  • Loading branch information
The-EDev authored Aug 5, 2022
2 parents c4e810f + e3f5c59 commit 6e7f0fb
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/unittest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1220,9 +1220,9 @@ TEST_CASE("template_function")
auto t = crow::mustache::compile("attack of {{func}}");
crow::mustache::context ctx;
ctx["name"] = "killer tomatoes";
ctx["func"] = [&](std::string) {
ctx["func"] = std::function<std::string(std::string)>([&](std::string) {
return std::string("{{name}}, IN SPACE!");
};
});
auto result = t.render_string(ctx);
CHECK("attack of killer tomatoes, IN SPACE!" == result);
}
Expand Down

0 comments on commit 6e7f0fb

Please sign in to comment.