File tree Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Expand file tree Collapse file tree 1 file changed +21
-0
lines changed Original file line number Diff line number Diff line change 1313#include < analyses/static_analysis.h>
1414#include < util/xml_expr.h>
1515#include < util/xml.h>
16+ #include < util/expr_util.h>
1617
1718#include " value_set_domain.h"
1819#include " value_sets.h"
@@ -108,6 +109,26 @@ class value_set_analysis_baset:
108109 dest,
109110 baset::ns);
110111 }
112+
113+ /* ******************************************************************\
114+
115+ Function: value_set_analysis_baset::is_singular
116+
117+ Inputs: The set of expressions to check.
118+
119+ Outputs: true, if it contains only one expression and
120+ that expression is a symbol,
121+ false, otherwise.
122+
123+ Purpose: Get whether a set of expressions can have a strong update
124+ or not.
125+
126+ \*******************************************************************/
127+
128+ virtual bool is_singular (const std::set<exprt> &values)
129+ {
130+ return values.size ()==1 && values.begin ()->id ()==ID_symbol;
131+ }
111132};
112133
113134typedef value_set_analysis_baset<value_sett> value_set_analysist;
You can’t perform that action at this time.
0 commit comments