3#include <boost/regex.hpp>
7 std::string indent(
' ', indentwidth);
8 std::cout << indent <<
"Intersection\n"
9 << indent <<
" first operand\n";
12 std::cout << indent <<
" second operand\n";
17 std::vector<std::shared_ptr<Base> >
first, firstrep,
second;
23 for (
auto item: firstrep) {
27 for (
auto item:
first) {
28 item->divideBy(firstrep);
29 bfuncs.emplace_back(item->clone());
32 for (
auto item:
first)
34 for (
auto item: firstrep)
44 boost::regex argumentList(
"(,[a-z]+\\(.*)");
45 boost::regex endParenthesis(
"\\)(.*)");
48 std::string str(it,
end);
49 if (!boost::regex_match(str, what, argumentList))
return false;
55 str = std::string(it,
end);
56 if (!boost::regex_match(str, what, endParenthesis))
return false;
58 std::string fullMatch = what[0];
59 std::string rest = what[1];
61 it += (fullMatch.size() - rest.size());
PartBunch< T, Dim >::ConstIterator end(PartBunch< T, Dim > const &bunch)
constexpr KOKKOS_INLINE_FUNCTION auto second()
constexpr KOKKOS_INLINE_FUNCTION auto first()
std::string::iterator iterator
virtual void apply(std::vector< std::shared_ptr< Base > > &bfuncs)=0
static bool parse(iterator &it, const iterator &end, Function *&fun)
virtual void print(int indent)=0
static bool parse_detail(iterator &it, const iterator &end, Function *&fun)
virtual void apply(std::vector< std::shared_ptr< Base > > &bfuncs)
virtual void print(int indentwidth)
Function * secondOperand_m
Function * firstOperand_m