MCPcopy Create free account
hub / github.com/argotorg/solidity / collectVariableNames

Method collectVariableNames

libsmtutil/CHCSmtLib2Interface.cpp:138–154  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

136}
137
138std::set<std::string> CHCSmtLib2Interface::collectVariableNames(Expression const& _expr) const
139{
140 std::set<std::string> names;
141 auto dfs = [&](Expression const& _current, auto _recurse) -> void
142 {
143 if (_current.arguments.empty())
144 {
145 if (m_context.isDeclared(_current.name))
146 names.insert(_current.name);
147 }
148 else
149 for (auto const& arg: _current.arguments)
150 _recurse(arg, _recurse);
151 };
152 dfs(_expr, dfs);
153 return names;
154}
155
156std::string CHCSmtLib2Interface::forall(Expression const& _expr)
157{

Callers

nothing calls this directly

Calls 3

isDeclaredMethod · 0.80
insertMethod · 0.80
emptyMethod · 0.45

Tested by

no test coverage detected