CBMC: /home/runner/work/cbmc/cbmc/src/util/std_expr.h File Reference
API to expression classes. More...
#include "deprecate.h"
#include "expr_cast.h"
#include "invariant.h"
#include "std_types.h"
Go to the source code of this file.
Classes | |
| class | nullary_exprt |
| An expression without operands. More... | |
| class | ternary_exprt |
| An expression with three operands. More... | |
| class | symbol_exprt |
| Expression to hold a symbol (variable) More... | |
| struct | std::hash<::symbol_exprt > |
| class | decorated_symbol_exprt |
| Expression to hold a symbol (variable) with extra accessors to ID_c_static_lifetime and ID_C_thread_local. More... | |
| class | nondet_symbol_exprt |
| Expression to hold a nondeterministic choice. More... | |
| class | unary_exprt |
| Generic base class for unary expressions. More... | |
| class | abs_exprt |
| Absolute value. More... | |
| class | unary_minus_exprt |
| The unary minus expression. More... | |
| class | unary_plus_exprt |
| The unary plus expression. More... | |
| class | predicate_exprt |
| A base class for expressions that are predicates, i.e., Boolean-typed. More... | |
| class | unary_predicate_exprt |
| A base class for expressions that are predicates, i.e., Boolean-typed, and that take exactly one argument. More... | |
| class | sign_exprt |
| Sign of an expression Predicate is true if _op is negative, false otherwise. More... | |
| class | binary_exprt |
| A base class for binary expressions. More... | |
| class | binary_predicate_exprt |
| A base class for expressions that are predicates, i.e., Boolean-typed, and that take exactly two arguments. More... | |
| class | binary_relation_exprt |
| A base class for relations, i.e., binary predicates whose two operands have the same type. More... | |
| class | greater_than_exprt |
| Binary greater than operator expression. More... | |
| class | greater_than_or_equal_exprt |
| Binary greater than or equal operator expression. More... | |
| class | less_than_exprt |
| Binary less than operator expression. More... | |
| class | less_than_or_equal_exprt |
| Binary less than or equal operator expression. More... | |
| class | multi_ary_exprt |
| A base class for multi-ary expressions Associativity is not specified. More... | |
| class | plus_exprt |
| The plus expression Associativity is not specified. More... | |
| class | minus_exprt |
| Binary minus. More... | |
| class | mult_exprt |
| Binary multiplication Associativity is not specified. More... | |
| class | div_exprt |
| Division. More... | |
| class | mod_exprt |
| Modulo defined as lhs-(rhs * truncate(lhs/rhs)). More... | |
| class | euclidean_mod_exprt |
| Boute's Euclidean definition of Modulo – to match SMT-LIB2. More... | |
| class | equal_exprt |
| Equality. More... | |
| class | notequal_exprt |
| Disequality. More... | |
| class | index_exprt |
| Array index operator. More... | |
| class | array_of_exprt |
| Array constructor from single element. More... | |
| class | array_exprt |
| Array constructor from list of elements. More... | |
| class | array_list_exprt |
| Array constructor from a list of index-element pairs Operands are index/value pairs, alternating. More... | |
| class | vector_exprt |
| Vector constructor from list of elements. More... | |
| class | union_exprt |
| Union constructor from single element. More... | |
| class | empty_union_exprt |
| Union constructor to support unions without any member (a GCC/Clang feature). More... | |
| class | struct_exprt |
| Struct constructor from list of elements. More... | |
| class | complex_exprt |
| Complex constructor from a pair of numbers. More... | |
| class | complex_real_exprt |
| Real part of the expression describing a complex number. More... | |
| class | complex_imag_exprt |
| Imaginary part of the expression describing a complex number. More... | |
| class | typecast_exprt |
| Semantic type conversion. More... | |
| class | and_exprt |
| Boolean AND All operands must be boolean, and the result is always boolean. More... | |
| class | nand_exprt |
| Boolean NAND. More... | |
| class | implies_exprt |
| Boolean implication. More... | |
| class | or_exprt |
| Boolean OR All operands must be boolean, and the result is always boolean. More... | |
| class | nor_exprt |
| Boolean NOR. More... | |
| class | xor_exprt |
| Boolean XOR All operands must be boolean, and the result is always boolean. More... | |
| class | xnor_exprt |
| Boolean XNOR. More... | |
| class | not_exprt |
| Boolean negation. More... | |
| class | if_exprt |
| The trinary if-then-else operator. More... | |
| class | with_exprt |
| Operator to update elements in structs and arrays. More... | |
| class | index_designatort |
| class | member_designatort |
| class | update_exprt |
| Operator to update elements in structs and arrays. More... | |
| class | member_exprt |
| Extract member of struct or union. More... | |
| class | type_exprt |
| An expression denoting a type. More... | |
| class | constant_exprt |
| A constant literal expression. More... | |
| class | true_exprt |
| The Boolean constant true. More... | |
| class | false_exprt |
| The Boolean constant false. More... | |
| class | nil_exprt |
| The NIL expression. More... | |
| class | infinity_exprt |
| An expression denoting infinity. More... | |
| class | binding_exprt |
| A base class for variable bindings (quantifiers, let, lambda) More... | |
| class | let_exprt |
| A let expression. More... | |
| class | cond_exprt |
| this is a parametric version of an if-expression: it returns the value of the first case (using the ordering of the operands) whose condition evaluates to true. More... | |
| class | case_exprt |
| Case expression: evaluates to the value corresponding to the first matching case. More... | |
| class | array_comprehension_exprt |
| Expression to define a mapping from an argument (index) to elements. More... | |
| class | class_method_descriptor_exprt |
| An expression describing a method on a class. More... | |
| class | named_term_exprt |
| Expression that introduces a new symbol that is equal to the operand. More... | |
Namespaces | |
| namespace | std |
| STL namespace. | |
API to expression classes.
Definition in file std_expr.h.
◆ can_cast_expr< abs_exprt >()
◆ can_cast_expr< and_exprt >()
◆ can_cast_expr< array_comprehension_exprt >()
◆ can_cast_expr< array_exprt >()
◆ can_cast_expr< array_list_exprt >()
◆ can_cast_expr< array_of_exprt >()
◆ can_cast_expr< binary_exprt >()
◆ can_cast_expr< binary_relation_exprt >()
◆ can_cast_expr< binding_exprt >()
◆ can_cast_expr< case_exprt >()
◆ can_cast_expr< class_method_descriptor_exprt >()
◆ can_cast_expr< complex_exprt >()
◆ can_cast_expr< complex_imag_exprt >()
◆ can_cast_expr< complex_real_exprt >()
◆ can_cast_expr< cond_exprt >()
◆ can_cast_expr< constant_exprt >()
◆ can_cast_expr< div_exprt >()
◆ can_cast_expr< empty_union_exprt >()
◆ can_cast_expr< equal_exprt >()
◆ can_cast_expr< euclidean_mod_exprt >()
◆ can_cast_expr< greater_than_exprt >()
◆ can_cast_expr< greater_than_or_equal_exprt >()
◆ can_cast_expr< if_exprt >()
◆ can_cast_expr< implies_exprt >()
◆ can_cast_expr< index_designatort >()
◆ can_cast_expr< index_exprt >()
◆ can_cast_expr< less_than_exprt >()
◆ can_cast_expr< less_than_or_equal_exprt >()
◆ can_cast_expr< let_exprt >()
◆ can_cast_expr< member_designatort >()
◆ can_cast_expr< member_exprt >()
◆ can_cast_expr< minus_exprt >()
◆ can_cast_expr< mod_exprt >()
◆ can_cast_expr< mult_exprt >()
◆ can_cast_expr< named_term_exprt >()
◆ can_cast_expr< nil_exprt >()
◆ can_cast_expr< nondet_symbol_exprt >()
◆ can_cast_expr< not_exprt >()
◆ can_cast_expr< notequal_exprt >()
◆ can_cast_expr< or_exprt >()
◆ can_cast_expr< plus_exprt >()
◆ can_cast_expr< sign_exprt >()
◆ can_cast_expr< struct_exprt >()
◆ can_cast_expr< symbol_exprt >()
◆ can_cast_expr< type_exprt >()
◆ can_cast_expr< typecast_exprt >()
◆ can_cast_expr< unary_exprt >()
◆ can_cast_expr< unary_minus_exprt >()
◆ can_cast_expr< unary_plus_exprt >()
◆ can_cast_expr< union_exprt >()
◆ can_cast_expr< update_exprt >()
◆ can_cast_expr< vector_exprt >()
◆ can_cast_expr< with_exprt >()
◆ can_cast_expr< xnor_exprt >()
◆ can_cast_expr< xor_exprt >()
◆ conjunction() [1/2]
1) generates a conjunction for two or more operands 2) for one operand, returns the operand 3) returns true otherwise
Definition at line 275 of file std_expr.cpp.
◆ conjunction() [2/2]
Conjunction of two expressions.
If the second is already an and_exprt add to its operands instead of creating a new expression. If one is true, return the other expression. If one is false returns false.
Definition at line 252 of file std_expr.cpp.
◆ disjunction()
1) generates a disjunction for two or more operands 2) for one operand, returns the operand 3) returns false otherwise
Definition at line 240 of file std_expr.cpp.
◆ operator!=() [1/3]
Return whether the expression lhs is not a constant of Boolean type or is not representing the Boolean value rhs.
Definition at line 37 of file std_expr.cpp.
◆ operator!=() [2/3]
◆ operator!=() [3/3]
◆ operator==() [1/3]
Return whether the expression lhs is a constant of Boolean type that is representing the Boolean value rhs.
Definition at line 32 of file std_expr.cpp.
◆ operator==() [2/3]
Return whether the expression lhs is a constant representing the numeric value rhs; only values 0 and 1 are supported for rhs.
For value 0 we consider the following types: ID_integer, ID_natural, ID_rational, ID_unsignedbv, ID_signedbv, ID_c_bool, ID_c_bit_field, ID_fixedbv, ID_floatbv, ID_pointer.
For ID_pointer, returns true iff the value is a zero string or a null pointer.
For value 1 we consider the following types: ID_integer, ID_natural, ID_rational, ID_unsignedbv, ID_signedbv, ID_c_bool, ID_c_bit_field, ID_fixedbv, ID_floatbv.
For all other types, return false.
Definition at line 52 of file std_expr.cpp.
◆ operator==() [3/3]
Return whether the expression lhs is a constant representing the NULL pointer.
Definition at line 186 of file std_expr.cpp.