13#ifndef CPROVER_TESTING_UTILS_EXPR_QUERY_H
14#define CPROVER_TESTING_UTILS_EXPR_QUERY_H
22template <
typename T = exprt>
26 std::is_base_of<exprt, T>::value,
27 "T should inherit from exprt");
34 template <
typename targett>
44 REQUIRE(
value.operands().size() > i);
Wrapper for optionalt<exprt> with useful method for queries to be used in unit tests.
expr_queryt< targett > as() const
expr_queryt< exprt > operator[](const std::size_t i) const
Base class for all expressions.
Templated functions to cast to specific exprt-derived classes.
auto expr_try_dynamic_cast(TExpr &base) -> typename detail::expr_try_dynamic_cast_return_typet< T, TExpr >::type
Try to cast a reference to a generic exprt to a specific derived class.
expr_queryt< exprt > make_query(exprt e)