return *this;
}
- // Postfix increment: requires a Proxy object to hold the
- // intermediate value for dereferencing
- class Proxy {
- const std::pair<const Key, Data>* d_pair;
-
- public:
-
- Proxy(const std::pair<const Key, Data>& p) : d_pair(&p) {}
-
- const std::pair<const Key, Data>& operator*() const {
- return *d_pair;
- }
- };/* class CDHashMap<>::iterator::Proxy */
-
- // Actual postfix increment: returns Proxy with the old value.
- // Now, an expression like *i++ will return the current *i, and
- // then advance the iterator. However, don't try to use
- // Proxy for anything else.
- const Proxy operator++(int) {
- Proxy e(*(*this));
- ++(*this);
- return e;
- }
+ // Postfix increment is not yet supported.
};/* class CDHashMap<>::iterator */
typedef iterator const_iterator;
return conjunction;
}/* mkAnd() */
- void TheorySetsRels::printNodeMap(char* fst, char* snd, NodeMap map) {
- NodeMap::iterator map_it = map.begin();
- while(map_it != map.end()) {
- Trace("rels-debug") << fst << " "<< (*map_it).first << " " << snd << " " << (*map_it).second<< std::endl;
- map_it++;
+ void TheorySetsRels::printNodeMap(const char* fst,
+ const char* snd,
+ const NodeMap& map)
+ {
+ for (const auto& key_data : map)
+ {
+ Trace("rels-debug") << fst << " " << key_data.first << " " << snd << " "
+ << key_data.second << std::endl;
}
}
-
}
}
}
bool exists( std::vector<Node>&, Node );
Node mkAnd( std::vector< TNode >& assumptions );
inline void addToMembershipDB( Node, Node, Node );
- void printNodeMap(char* fst, char* snd, NodeMap map);
+ static void printNodeMap(const char* fst,
+ const char* snd,
+ const NodeMap& map);
inline Node constructPair(Node tc_rep, Node a, Node b);
void addToMap( std::map< Node, std::vector<Node> >&, Node, Node );
bool safelyAddToMap( std::map< Node, std::vector<Node> >&, Node, Node );