| souffle
    2.0.2-371-g6315b36
    | 
 
 
 
Go to the documentation of this file.
   36 class Term : 
public Argument {
 
   38     template <
typename... Operands>
 
   39     Term(Operands&&... operands) : 
Term(
asVec(
std::forward<Operands>(operands)...)) {}
 
   41     template <
typename... Operands>
 
   56         args.push_back(std::move(arg));
 
   62             res.push_back(cur.get());
 
   68         for (
auto& arg : 
args) {
 
   69             arg = 
map(std::move(arg));
 
   74     bool equal(
const Node& node)
 const override {
 
   75         const auto& other = 
static_cast<const Term&
>(node);
 
   83     template <
typename... Operands>
 
   87         for (
auto&& x : ary) {
 
   88             xs.push_back(std::move(x));
 
  
VecOwn< Argument > args
Arguments.
std::vector< const Node * > getChildNodes() const override
Obtain a list of all embedded AST child nodes.
void apply(const NodeMapper &map) override
Apply the mapper to all child nodes.
An abstract class for manipulating AST Nodes by substitution.
auto map(const std::vector< A > &xs, F &&f)
Applies a function to each element of a vector and returns the results.
An abstract class for arguments.
bool equal_targets(const Container &a, const Container &b, const Comparator &comp)
A function testing whether two containers are equal with the given Comparator.
void addArgument(Own< Argument > arg)
Add argument to argument list.
static VecOwn< Argument > asVec(Operands... ops)
std::vector< Argument * > getArguments() const
Get arguments.
virtual std::vector< const Node * > getChildNodes() const
Obtain a list of all embedded AST child nodes.
Abstract class for syntactic elements in an input program.
Defines an abstract term class used for functors and other constructors.
A class describing a range in an input file.
bool equal(const Node &node) const override
Abstract equality check for two AST nodes.
std::vector< T * > toPtrVector(const std::vector< std::unique_ptr< T >> &v)
A utility function enabling the creation of a vector of pointers.
std::vector< Own< A > > VecOwn
Term(Operands &&... operands)