Operations with no arguments
Operations with exactly one argument
Operations with exactly two argument
Operations with exactly three argument
Operations with variable number of arguments, requiring that the number of arguments is greater than least numRequired
Operations with variable number of arguments, none required
Operations with variable number of arguments, at least one required
Operations with variable number of arguments, at least two required
Operations with variable number of arguments, at least two required
Corresponds to the many operations that are defined for two arguments and
marked as :left-assoc or :pairwise (such as and
or distinct
). Note that
the resulting representation in terms of AST will be the n-ary function application,
and not the desugared version (successive binary operation). This choice seems to
make sense for operations such as distinct that would require an exponential
blowup to desugar the expression, while the latest phase of the solvers might
be able to do something smarter with the more concise operation.
Operations with variable number of arguments, at least three required
General patterns for building and extracting FunctionApplication in theories.
Most SMT-LIB theories are a definition of many built-in functions. We do not wish to extend the core abstract syntax tree of SMT-LIB with theory specific operations, so a theory definition is simply providing Constructors and Extractors to build the proper trees out of core SMT-LIB FunctionApplication and Identifier.
this object provides traits to facilitate the definition of custom FunctionApplication with apply and unapply methods. They provide the proper signatures for different arities.
Refer to any theory definition to see examples of how to use these traits.