LRDE Tiger Compiler
1.34a $Id: 7fef12e1f5fa43449d667a0eec1d837c40fc1202 $
|
Some syntactic sugar to look for things in STL containers. More...
Go to the source code of this file.
Namespaces | |
namespace | misc |
Handling of generic, oriented or undirected, graph. |
Functions | |
template<typename Container > | |
void | misc::deep_clear (Container &c) |
Invoke delete on all the members of c, and clear it. | |
template<typename Container > | |
Container::const_iterator | misc::find (const Container &c, const typename Container::value_type &v) |
Find v in the whole c. | |
template<typename Container > | |
Container::iterator | misc::find (Container &c, const typename Container::value_type &v) |
Find v in the whole c. | |
template<typename Container , typename Functor > | |
Functor & | misc::for_each (Container &c, Functor &v) |
Apply f to all the members of c, and return it. | |
template<typename Container > | |
bool | misc::has (const Container &c, const typename Container::value_type &v) |
Is v member of c? | |
template<typename Map > | |
Map::iterator | misc::put (Map &map, const typename Map::key_type &key, const typename Map::mapped_type &value) |
Insert or update key -> value in map, return iterator to it. |
Some syntactic sugar to look for things in STL containers.