Fix nested function (#159)
* switched order in token::kind::id of function and operator behavior
* add tests
* fixed nested function order
* created single include
Co-authored-by: pantor <lars.berscheid@online.de>
diff --git a/include/inja/parser.hpp b/include/inja/parser.hpp
index 348f315..b22e04d 100644
--- a/include/inja/parser.hpp
+++ b/include/inja/parser.hpp
@@ -289,6 +289,9 @@
}
function_stack.pop();
+
+ current_expression_list->rpn_output.emplace_back(operator_stack.top());
+ operator_stack.pop();
}
}
default:
diff --git a/single_include/inja/inja.hpp b/single_include/inja/inja.hpp
index ec9937d..45595d0 100644
--- a/single_include/inja/inja.hpp
+++ b/single_include/inja/inja.hpp
@@ -3001,6 +3001,9 @@
}
function_stack.pop();
+
+ current_expression_list->rpn_output.emplace_back(operator_stack.top());
+ operator_stack.pop();
}
}
default: