35 bool tupleNotUsed =
true;
37 if (element.getTupleId() == indexScan->getTupleId()) {
47 size_t arity = indexScan->getRangePattern().first.size();
48 for (
size_t i = 0;
i < arity; ++
i) {
49 if (*(indexScan->getRangePattern().first[
i]) != *(indexScan->getRangePattern().second[
i])) {
54 for (
auto& cur : indexScan->getRangePattern().second) {
59 newValues.emplace_back(val);
64 if (
const auto* breakOp =
dynamic_cast<const Break*
>(&indexScan->getOperation())) {
65 newOp = breakOp->getOperation().
clone();
67 newOp = indexScan->getOperation().
clone();
70 return mk<Filter>(mk<ExistenceCheck>(indexScan->getRelation(), std::move(newValues)),
71 Own<Operation>(newOp), indexScan->getProfileText());
79 std::function<Own<Node>(Own<Node>)> scanRewriter = [&](Own<Node> node) -> Own<Node> {