7#include "formula_binary_operator_node.hpp"
8#include "formula_post_process_context.hpp"
9#include "formula_name_node.hpp"
11namespace hi::inline
v1 {
21 if (rhs_name ==
nullptr) {
22 throw parse_error(std::format(
"{}: Expecting a name token on the right hand side of a filter operator. got {}.", location, *rhs));
28 formula_binary_operator_node::post_process(context);
30 filter = context.get_filter(rhs_name->name);
32 throw parse_error(std::format(
"{}: Could not find filter .{}().", location, rhs_name->name));
38 auto lhs_ = lhs->evaluate(context);
42 throw operation_error(std::format(
"{}: Can not evaluate filter.\n{}", location, e.
what()));
48 return std::format(
"({} ! {})", *lhs, *rhs);
DOXYGEN BUG.
Definition algorithm.hpp:13
A dynamic data type.
Definition datum.hpp:219
Definition formula_binary_operator_node.hpp:11
Definition formula_evaluation_context.hpp:15
Definition formula_filter_node.hpp:13
void post_process(formula_post_process_context &context) override
Resolve function and method pointers.
Definition formula_filter_node.hpp:26
datum evaluate(formula_evaluation_context &context) const override
Evaluate an rvalue.
Definition formula_filter_node.hpp:36
Definition formula_name_node.hpp:11
Definition formula_post_process_context.hpp:19
Definition parse_location.hpp:18