Index: lemon/bin_heap.h
===================================================================
--- lemon/bin_heap.h	(revision 631)
+++ lemon/bin_heap.h	(revision 730)
@@ -34,9 +34,9 @@
   ///\brief A Binary Heap implementation.
   ///
-  ///This class implements the \e binary \e heap data structure. 
-  /// 
+  ///This class implements the \e binary \e heap data structure.
+  ///
   ///A \e heap is a data structure for storing items with specified values
   ///called \e priorities in such a way that finding the item with minimum
-  ///priority is efficient. \c Comp specifies the ordering of the priorities.
+  ///priority is efficient. \c CMP specifies the ordering of the priorities.
   ///In a heap one can change the priority of an item, add or erase an
   ///item, etc.
@@ -45,10 +45,10 @@
   ///\tparam IM A read and writable item map with int values, used internally
   ///to handle the cross references.
-  ///\tparam Comp A functor class for the ordering of the priorities.
+  ///\tparam CMP A functor class for the ordering of the priorities.
   ///The default is \c std::less<PR>.
   ///
   ///\sa FibHeap
   ///\sa Dijkstra
-  template <typename PR, typename IM, typename Comp = std::less<PR> >
+  template <typename PR, typename IM, typename CMP = std::less<PR> >
   class BinHeap {
 
@@ -63,5 +63,5 @@
     typedef std::pair<Item,Prio> Pair;
     ///\e
-    typedef Comp Compare;
+    typedef CMP Compare;
 
     /// \brief Type to represent the items states.
Index: lemon/bucket_heap.h
===================================================================
--- lemon/bucket_heap.h	(revision 729)
+++ lemon/bucket_heap.h	(revision 730)
@@ -32,5 +32,5 @@
   namespace _bucket_heap_bits {
 
-    template <bool minimize>
+    template <bool MIN>
     struct DirectionTraits {
       static bool less(int left, int right) {
@@ -66,14 +66,15 @@
   /// the priorities are small. It is not intended to use as dijkstra heap.
   ///
-  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// \param IM A read and write Item int map, used internally
   /// to handle the cross references.
-  /// \param minimize If the given parameter is true then the heap gives back
-  /// the lowest priority.
-  template <typename _ItemIntMap, bool minimize = true>
+  /// \param MIN If the given parameter is false then instead of the
+  /// minimum value the maximum can be retrivied with the top() and
+  /// prio() member functions.
+  template <typename IM, bool MIN = true>
   class BucketHeap {
 
   public:
     /// \e
-    typedef typename _ItemIntMap::Key Item;
+    typedef typename IM::Key Item;
     /// \e
     typedef int Prio;
@@ -81,9 +82,9 @@
     typedef std::pair<Item, Prio> Pair;
     /// \e
-    typedef _ItemIntMap ItemIntMap;
+    typedef IM ItemIntMap;
 
   private:
 
-    typedef _bucket_heap_bits::DirectionTraits<minimize> Direction;
+    typedef _bucket_heap_bits::DirectionTraits<MIN> Direction;
 
   public:
@@ -95,10 +96,10 @@
     /// heap's point of view, but may be useful to the user.
     ///
-    /// The ItemIntMap \e should be initialized in such way that it maps
-    /// PRE_HEAP (-1) to any element to be put in the heap...
+    /// The item-int map must be initialized in such way that it assigns
+    /// \c PRE_HEAP (<tt>-1</tt>) to any element to be put in the heap.
     enum State {
-      IN_HEAP = 0,
-      PRE_HEAP = -1,
-      POST_HEAP = -2
+      IN_HEAP = 0,    ///< = 0.
+      PRE_HEAP = -1,  ///< = -1.
+      POST_HEAP = -2  ///< = -2.
     };
 
@@ -107,18 +108,18 @@
     ///
     /// The constructor.
-    /// \param _index should be given to the constructor, since it is used
+    /// \param map should be given to the constructor, since it is used
     /// internally to handle the cross references. The value of the map
     /// should be PRE_HEAP (-1) for each element.
-    explicit BucketHeap(ItemIntMap &_index) : index(_index), minimal(0) {}
+    explicit BucketHeap(ItemIntMap &map) : _iim(map), _minimum(0) {}
 
     /// The number of items stored in the heap.
     ///
     /// \brief Returns the number of items stored in the heap.
-    int size() const { return data.size(); }
+    int size() const { return _data.size(); }
 
     /// \brief Checks if the heap stores no items.
     ///
     /// Returns \c true if and only if the heap stores no items.
-    bool empty() const { return data.empty(); }
+    bool empty() const { return _data.empty(); }
 
     /// \brief Make empty this heap.
@@ -129,5 +130,5 @@
     /// cross reference map for each item to \c PRE_HEAP.
     void clear() {
-      data.clear(); first.clear(); minimal = 0;
+      _data.clear(); _first.clear(); _minimum = 0;
     }
 
@@ -135,40 +136,40 @@
 
     void relocate_last(int idx) {
-      if (idx + 1 < int(data.size())) {
-        data[idx] = data.back();
-        if (data[idx].prev != -1) {
-          data[data[idx].prev].next = idx;
+      if (idx + 1 < int(_data.size())) {
+        _data[idx] = _data.back();
+        if (_data[idx].prev != -1) {
+          _data[_data[idx].prev].next = idx;
         } else {
-          first[data[idx].value] = idx;
+          _first[_data[idx].value] = idx;
         }
-        if (data[idx].next != -1) {
-          data[data[idx].next].prev = idx;
+        if (_data[idx].next != -1) {
+          _data[_data[idx].next].prev = idx;
         }
-        index[data[idx].item] = idx;
-      }
-      data.pop_back();
+        _iim[_data[idx].item] = idx;
+      }
+      _data.pop_back();
     }
 
     void unlace(int idx) {
-      if (data[idx].prev != -1) {
-        data[data[idx].prev].next = data[idx].next;
+      if (_data[idx].prev != -1) {
+        _data[_data[idx].prev].next = _data[idx].next;
       } else {
-        first[data[idx].value] = data[idx].next;
-      }
-      if (data[idx].next != -1) {
-        data[data[idx].next].prev = data[idx].prev;
+        _first[_data[idx].value] = _data[idx].next;
+      }
+      if (_data[idx].next != -1) {
+        _data[_data[idx].next].prev = _data[idx].prev;
       }
     }
 
     void lace(int idx) {
-      if (int(first.size()) <= data[idx].value) {
-        first.resize(data[idx].value + 1, -1);
-      }
-      data[idx].next = first[data[idx].value];
-      if (data[idx].next != -1) {
-        data[data[idx].next].prev = idx;
-      }
-      first[data[idx].value] = idx;
-      data[idx].prev = -1;
+      if (int(_first.size()) <= _data[idx].value) {
+        _first.resize(_data[idx].value + 1, -1);
+      }
+      _data[idx].next = _first[_data[idx].value];
+      if (_data[idx].next != -1) {
+        _data[_data[idx].next].prev = idx;
+      }
+      _first[_data[idx].value] = idx;
+      _data[idx].prev = -1;
     }
 
@@ -188,10 +189,10 @@
     /// \param p The priority of the item.
     void push(const Item &i, const Prio &p) {
-      int idx = data.size();
-      index[i] = idx;
-      data.push_back(BucketItem(i, p));
+      int idx = _data.size();
+      _iim[i] = idx;
+      _data.push_back(BucketItem(i, p));
       lace(idx);
-      if (Direction::less(p, minimal)) {
-        minimal = p;
+      if (Direction::less(p, _minimum)) {
+        _minimum = p;
       }
     }
@@ -202,8 +203,8 @@
     /// \pre The heap must be nonempty.
     Item top() const {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      return data[first[minimal]].item;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      return _data[_first[_minimum]].item;
     }
 
@@ -213,8 +214,8 @@
     /// \pre The heap must be nonempty.
     Prio prio() const {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      return minimal;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      return _minimum;
     }
 
@@ -224,9 +225,9 @@
     /// \pre The heap must be non-empty.
     void pop() {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      int idx = first[minimal];
-      index[data[idx].item] = -2;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      int idx = _first[_minimum];
+      _iim[_data[idx].item] = -2;
       unlace(idx);
       relocate_last(idx);
@@ -239,6 +240,6 @@
     /// \param i The item to erase.
     void erase(const Item &i) {
-      int idx = index[i];
-      index[data[idx].item] = -2;
+      int idx = _iim[i];
+      _iim[_data[idx].item] = -2;
       unlace(idx);
       relocate_last(idx);
@@ -252,6 +253,6 @@
     /// \param i The item.
     Prio operator[](const Item &i) const {
-      int idx = index[i];
-      return data[idx].value;
+      int idx = _iim[i];
+      return _data[idx].value;
     }
 
@@ -264,8 +265,8 @@
     /// \param p The priority.
     void set(const Item &i, const Prio &p) {
-      int idx = index[i];
+      int idx = _iim[i];
       if (idx < 0) {
         push(i, p);
-      } else if (Direction::less(p, data[idx].value)) {
+      } else if (Direction::less(p, _data[idx].value)) {
         decrease(i, p);
       } else {
@@ -282,9 +283,9 @@
     /// \param p The priority.
     void decrease(const Item &i, const Prio &p) {
-      int idx = index[i];
+      int idx = _iim[i];
       unlace(idx);
-      data[idx].value = p;
-      if (Direction::less(p, minimal)) {
-        minimal = p;
+      _data[idx].value = p;
+      if (Direction::less(p, _minimum)) {
+        _minimum = p;
       }
       lace(idx);
@@ -299,7 +300,7 @@
     /// \param p The priority.
     void increase(const Item &i, const Prio &p) {
-      int idx = index[i];
+      int idx = _iim[i];
       unlace(idx);
-      data[idx].value = p;
+      _data[idx].value = p;
       lace(idx);
     }
@@ -314,5 +315,5 @@
     /// \param i The item.
     State state(const Item &i) const {
-      int idx = index[i];
+      int idx = _iim[i];
       if (idx >= 0) idx = 0;
       return State(idx);
@@ -333,5 +334,5 @@
           erase(i);
         }
-        index[i] = st;
+        _iim[i] = st;
         break;
       case IN_HEAP:
@@ -352,8 +353,8 @@
     };
 
-    ItemIntMap& index;
-    std::vector<int> first;
-    std::vector<BucketItem> data;
-    mutable int minimal;
+    ItemIntMap& _iim;
+    std::vector<int> _first;
+    std::vector<BucketItem> _data;
+    mutable int _minimum;
 
   }; // class BucketHeap
@@ -371,22 +372,23 @@
   /// minimal and it does not supports key increasing, decreasing.
   ///
-  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// \param IM A read and write Item int map, used internally
   /// to handle the cross references.
-  /// \param minimize If the given parameter is true then the heap gives back
-  /// the lowest priority.
+  /// \param MIN If the given parameter is false then instead of the
+  /// minimum value the maximum can be retrivied with the top() and
+  /// prio() member functions.
   ///
   /// \sa BucketHeap
-  template <typename _ItemIntMap, bool minimize = true >
+  template <typename IM, bool MIN = true >
   class SimpleBucketHeap {
 
   public:
-    typedef typename _ItemIntMap::Key Item;
+    typedef typename IM::Key Item;
     typedef int Prio;
     typedef std::pair<Item, Prio> Pair;
-    typedef _ItemIntMap ItemIntMap;
+    typedef IM ItemIntMap;
 
   private:
 
-    typedef _bucket_heap_bits::DirectionTraits<minimize> Direction;
+    typedef _bucket_heap_bits::DirectionTraits<MIN> Direction;
 
   public:
@@ -398,10 +400,10 @@
     /// heap's point of view, but may be useful to the user.
     ///
-    /// The ItemIntMap \e should be initialized in such way that it maps
-    /// PRE_HEAP (-1) to any element to be put in the heap...
+    /// The item-int map must be initialized in such way that it assigns
+    /// \c PRE_HEAP (<tt>-1</tt>) to any element to be put in the heap.
     enum State {
-      IN_HEAP = 0,
-      PRE_HEAP = -1,
-      POST_HEAP = -2
+      IN_HEAP = 0,    ///< = 0.
+      PRE_HEAP = -1,  ///< = -1.
+      POST_HEAP = -2  ///< = -2.
     };
 
@@ -411,19 +413,19 @@
     ///
     /// The constructor.
-    /// \param _index should be given to the constructor, since it is used
+    /// \param map should be given to the constructor, since it is used
     /// internally to handle the cross references. The value of the map
     /// should be PRE_HEAP (-1) for each element.
-    explicit SimpleBucketHeap(ItemIntMap &_index)
-      : index(_index), free(-1), num(0), minimal(0) {}
+    explicit SimpleBucketHeap(ItemIntMap &map)
+      : _iim(map), _free(-1), _num(0), _minimum(0) {}
 
     /// \brief Returns the number of items stored in the heap.
     ///
     /// The number of items stored in the heap.
-    int size() const { return num; }
+    int size() const { return _num; }
 
     /// \brief Checks if the heap stores no items.
     ///
     /// Returns \c true if and only if the heap stores no items.
-    bool empty() const { return num == 0; }
+    bool empty() const { return _num == 0; }
 
     /// \brief Make empty this heap.
@@ -434,5 +436,5 @@
     /// cross reference map for each item to \c PRE_HEAP.
     void clear() {
-      data.clear(); first.clear(); free = -1; num = 0; minimal = 0;
+      _data.clear(); _first.clear(); _free = -1; _num = 0; _minimum = 0;
     }
 
@@ -452,20 +454,20 @@
     void push(const Item &i, const Prio &p) {
       int idx;
-      if (free == -1) {
-        idx = data.size();
-        data.push_back(BucketItem(i));
+      if (_free == -1) {
+        idx = _data.size();
+        _data.push_back(BucketItem(i));
       } else {
-        idx = free;
-        free = data[idx].next;
-        data[idx].item = i;
-      }
-      index[i] = idx;
-      if (p >= int(first.size())) first.resize(p + 1, -1);
-      data[idx].next = first[p];
-      first[p] = idx;
-      if (Direction::less(p, minimal)) {
-        minimal = p;
-      }
-      ++num;
+        idx = _free;
+        _free = _data[idx].next;
+        _data[idx].item = i;
+      }
+      _iim[i] = idx;
+      if (p >= int(_first.size())) _first.resize(p + 1, -1);
+      _data[idx].next = _first[p];
+      _first[p] = idx;
+      if (Direction::less(p, _minimum)) {
+        _minimum = p;
+      }
+      ++_num;
     }
 
@@ -475,8 +477,8 @@
     /// \pre The heap must be nonempty.
     Item top() const {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      return data[first[minimal]].item;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      return _data[_first[_minimum]].item;
     }
 
@@ -486,8 +488,8 @@
     /// \pre The heap must be nonempty.
     Prio prio() const {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      return minimal;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      return _minimum;
     }
 
@@ -497,13 +499,13 @@
     /// \pre The heap must be non-empty.
     void pop() {
-      while (first[minimal] == -1) {
-        Direction::increase(minimal);
-      }
-      int idx = first[minimal];
-      index[data[idx].item] = -2;
-      first[minimal] = data[idx].next;
-      data[idx].next = free;
-      free = idx;
-      --num;
+      while (_first[_minimum] == -1) {
+        Direction::increase(_minimum);
+      }
+      int idx = _first[_minimum];
+      _iim[_data[idx].item] = -2;
+      _first[_minimum] = _data[idx].next;
+      _data[idx].next = _free;
+      _free = idx;
+      --_num;
     }
 
@@ -517,11 +519,11 @@
     /// \param i The item.
     Prio operator[](const Item &i) const {
-      for (int k = 0; k < first.size(); ++k) {
-        int idx = first[k];
+      for (int k = 0; k < _first.size(); ++k) {
+        int idx = _first[k];
         while (idx != -1) {
-          if (data[idx].item == i) {
+          if (_data[idx].item == i) {
             return k;
           }
-          idx = data[idx].next;
+          idx = _data[idx].next;
         }
       }
@@ -538,5 +540,5 @@
     /// \param i The item.
     State state(const Item &i) const {
-      int idx = index[i];
+      int idx = _iim[i];
       if (idx >= 0) idx = 0;
       return State(idx);
@@ -553,9 +555,9 @@
     };
 
-    ItemIntMap& index;
-    std::vector<int> first;
-    std::vector<BucketItem> data;
-    int free, num;
-    mutable int minimal;
+    ItemIntMap& _iim;
+    std::vector<int> _first;
+    std::vector<BucketItem> _data;
+    int _free, _num;
+    mutable int _minimum;
 
   }; // class SimpleBucketHeap
Index: lemon/fib_heap.h
===================================================================
--- lemon/fib_heap.h	(revision 728)
+++ lemon/fib_heap.h	(revision 730)
@@ -37,5 +37,5 @@
   ///is a data structure for storing items with specified values called \e
   ///priorities in such a way that finding the item with minimum priority is
-  ///efficient. \c Compare specifies the ordering of the priorities. In a heap
+  ///efficient. \c CMP specifies the ordering of the priorities. In a heap
   ///one can change the priority of an item, add or erase an item, etc.
   ///
@@ -44,27 +44,23 @@
   ///\ref BinHeap "binary heap".
   ///
-  ///\param _Prio Type of the priority of the items.
-  ///\param _ItemIntMap A read and writable Item int map, used internally
+  ///\param PRIO Type of the priority of the items.
+  ///\param IM A read and writable Item int map, used internally
   ///to handle the cross references.
-  ///\param _Compare A class for the ordering of the priorities. The
-  ///default is \c std::less<_Prio>.
+  ///\param CMP A class for the ordering of the priorities. The
+  ///default is \c std::less<PRIO>.
   ///
   ///\sa BinHeap
   ///\sa Dijkstra
 #ifdef DOXYGEN
-  template <typename _Prio,
-            typename _ItemIntMap,
-            typename _Compare>
+  template <typename PRIO, typename IM, typename CMP>
 #else
-  template <typename _Prio,
-            typename _ItemIntMap,
-            typename _Compare = std::less<_Prio> >
+  template <typename PRIO, typename IM, typename CMP = std::less<PRIO> >
 #endif
   class FibHeap {
   public:
     ///\e
-    typedef _ItemIntMap ItemIntMap;
+    typedef IM ItemIntMap;
     ///\e
-    typedef _Prio Prio;
+    typedef PRIO Prio;
     ///\e
     typedef typename ItemIntMap::Key Item;
@@ -72,50 +68,55 @@
     typedef std::pair<Item,Prio> Pair;
     ///\e
-    typedef _Compare Compare;
+    typedef CMP Compare;
 
   private:
-    class store;
-
-    std::vector<store> container;
-    int minimum;
-    ItemIntMap &iimap;
-    Compare comp;
-    int num_items;
+    class Store;
+
+    std::vector<Store> _data;
+    int _minimum;
+    ItemIntMap &_iim;
+    Compare _comp;
+    int _num;
 
   public:
-    ///Status of the nodes
+
+    /// \brief Type to represent the items states.
+    ///
+    /// Each Item element have a state associated to it. It may be "in heap",
+    /// "pre heap" or "post heap". The latter two are indifferent from the
+    /// heap's point of view, but may be useful to the user.
+    ///
+    /// The item-int map must be initialized in such way that it assigns
+    /// \c PRE_HEAP (<tt>-1</tt>) to any element to be put in the heap.
     enum State {
-      ///The node is in the heap
-      IN_HEAP = 0,
-      ///The node has never been in the heap
-      PRE_HEAP = -1,
-      ///The node was in the heap but it got out of it
-      POST_HEAP = -2
+      IN_HEAP = 0,    ///< = 0.
+      PRE_HEAP = -1,  ///< = -1.
+      POST_HEAP = -2  ///< = -2.
     };
 
     /// \brief The constructor
     ///
-    /// \c _iimap should be given to the constructor, since it is
+    /// \c map should be given to the constructor, since it is
     ///   used internally to handle the cross references.
-    explicit FibHeap(ItemIntMap &_iimap)
-      : minimum(0), iimap(_iimap), num_items() {}
+    explicit FibHeap(ItemIntMap &map)
+      : _minimum(0), _iim(map), _num() {}
 
     /// \brief The constructor
     ///
-    /// \c _iimap should be given to the constructor, since it is used
-    /// internally to handle the cross references. \c _comp is an
+    /// \c map should be given to the constructor, since it is used
+    /// internally to handle the cross references. \c comp is an
     /// object for ordering of the priorities.
-    FibHeap(ItemIntMap &_iimap, const Compare &_comp)
-      : minimum(0), iimap(_iimap), comp(_comp), num_items() {}
+    FibHeap(ItemIntMap &map, const Compare &comp)
+      : _minimum(0), _iim(map), _comp(comp), _num() {}
 
     /// \brief The number of items stored in the heap.
     ///
     /// Returns the number of items stored in the heap.
-    int size() const { return num_items; }
+    int size() const { return _num; }
 
     /// \brief Checks if the heap stores no items.
     ///
     ///   Returns \c true if and only if the heap stores no items.
-    bool empty() const { return num_items==0; }
+    bool empty() const { return _num==0; }
 
     /// \brief Make empty this heap.
@@ -126,5 +127,5 @@
     /// cross reference map for each item to \c PRE_HEAP.
     void clear() {
-      container.clear(); minimum = 0; num_items = 0;
+      _data.clear(); _minimum = 0; _num = 0;
     }
 
@@ -136,8 +137,8 @@
     /// \ref increase(\c item, \c value) otherwise.
     void set (const Item& item, const Prio& value) {
-      int i=iimap[item];
-      if ( i >= 0 && container[i].in ) {
-        if ( comp(value, container[i].prio) ) decrease(item, value);
-        if ( comp(container[i].prio, value) ) increase(item, value);
+      int i=_iim[item];
+      if ( i >= 0 && _data[i].in ) {
+        if ( _comp(value, _data[i].prio) ) decrease(item, value);
+        if ( _comp(_data[i].prio, value) ) increase(item, value);
       } else push(item, value);
     }
@@ -148,31 +149,31 @@
     /// \pre \c item must not be stored in the heap.
     void push (const Item& item, const Prio& value) {
-      int i=iimap[item];
+      int i=_iim[item];
       if ( i < 0 ) {
-        int s=container.size();
-        iimap.set( item, s );
-        store st;
+        int s=_data.size();
+        _iim.set( item, s );
+        Store st;
         st.name=item;
-        container.push_back(st);
+        _data.push_back(st);
         i=s;
       } else {
-        container[i].parent=container[i].child=-1;
-        container[i].degree=0;
-        container[i].in=true;
-        container[i].marked=false;
-      }
-
-      if ( num_items ) {
-        container[container[minimum].right_neighbor].left_neighbor=i;
-        container[i].right_neighbor=container[minimum].right_neighbor;
-        container[minimum].right_neighbor=i;
-        container[i].left_neighbor=minimum;
-        if ( comp( value, container[minimum].prio) ) minimum=i;
+        _data[i].parent=_data[i].child=-1;
+        _data[i].degree=0;
+        _data[i].in=true;
+        _data[i].marked=false;
+      }
+
+      if ( _num ) {
+        _data[_data[_minimum].right_neighbor].left_neighbor=i;
+        _data[i].right_neighbor=_data[_minimum].right_neighbor;
+        _data[_minimum].right_neighbor=i;
+        _data[i].left_neighbor=_minimum;
+        if ( _comp( value, _data[_minimum].prio) ) _minimum=i;
       } else {
-        container[i].right_neighbor=container[i].left_neighbor=i;
-        minimum=i;
-      }
-      container[i].prio=value;
-      ++num_items;
+        _data[i].right_neighbor=_data[i].left_neighbor=i;
+        _minimum=i;
+      }
+      _data[i].prio=value;
+      ++_num;
     }
 
@@ -182,5 +183,5 @@
     /// Compare.
     /// \pre The heap must be nonempty.
-    Item top() const { return container[minimum].name; }
+    Item top() const { return _data[_minimum].name; }
 
     /// \brief Returns the minimum priority relative to \c Compare.
@@ -188,5 +189,5 @@
     /// It returns the minimum priority relative to \c Compare.
     /// \pre The heap must be nonempty.
-    const Prio& prio() const { return container[minimum].prio; }
+    const Prio& prio() const { return _data[_minimum].prio; }
 
     /// \brief Returns the priority of \c item.
@@ -195,5 +196,5 @@
     /// \pre \c item must be in the heap.
     const Prio& operator[](const Item& item) const {
-      return container[iimap[item]].prio;
+      return _data[_iim[item]].prio;
     }
 
@@ -205,31 +206,31 @@
     void pop() {
       /*The first case is that there are only one root.*/
-      if ( container[minimum].left_neighbor==minimum ) {
-        container[minimum].in=false;
-        if ( container[minimum].degree!=0 ) {
-          makeroot(container[minimum].child);
-          minimum=container[minimum].child;
+      if ( _data[_minimum].left_neighbor==_minimum ) {
+        _data[_minimum].in=false;
+        if ( _data[_minimum].degree!=0 ) {
+          makeroot(_data[_minimum].child);
+          _minimum=_data[_minimum].child;
           balance();
         }
       } else {
-        int right=container[minimum].right_neighbor;
-        unlace(minimum);
-        container[minimum].in=false;
-        if ( container[minimum].degree > 0 ) {
-          int left=container[minimum].left_neighbor;
-          int child=container[minimum].child;
-          int last_child=container[child].left_neighbor;
+        int right=_data[_minimum].right_neighbor;
+        unlace(_minimum);
+        _data[_minimum].in=false;
+        if ( _data[_minimum].degree > 0 ) {
+          int left=_data[_minimum].left_neighbor;
+          int child=_data[_minimum].child;
+          int last_child=_data[child].left_neighbor;
 
           makeroot(child);
 
-          container[left].right_neighbor=child;
-          container[child].left_neighbor=left;
-          container[right].left_neighbor=last_child;
-          container[last_child].right_neighbor=right;
-        }
-        minimum=right;
+          _data[left].right_neighbor=child;
+          _data[child].left_neighbor=left;
+          _data[right].left_neighbor=last_child;
+          _data[last_child].right_neighbor=right;
+        }
+        _minimum=right;
         balance();
       } // the case where there are more roots
-      --num_items;
+      --_num;
     }
 
@@ -239,13 +240,13 @@
     /// stored in the heap. It is quite inefficient in Fibonacci heaps.
     void erase (const Item& item) {
-      int i=iimap[item];
-
-      if ( i >= 0 && container[i].in ) {
-        if ( container[i].parent!=-1 ) {
-          int p=container[i].parent;
+      int i=_iim[item];
+
+      if ( i >= 0 && _data[i].in ) {
+        if ( _data[i].parent!=-1 ) {
+          int p=_data[i].parent;
           cut(i,p);
           cascade(p);
         }
-        minimum=i;     //As if its prio would be -infinity
+        _minimum=i;     //As if its prio would be -infinity
         pop();
       }
@@ -258,13 +259,13 @@
     ///   value relative to \c Compare.
     void decrease (Item item, const Prio& value) {
-      int i=iimap[item];
-      container[i].prio=value;
-      int p=container[i].parent;
-
-      if ( p!=-1 && comp(value, container[p].prio) ) {
+      int i=_iim[item];
+      _data[i].prio=value;
+      int p=_data[i].parent;
+
+      if ( p!=-1 && _comp(value, _data[p].prio) ) {
         cut(i,p);
         cascade(p);
       }
-      if ( comp(value, container[minimum].prio) ) minimum=i;
+      if ( _comp(value, _data[_minimum].prio) ) _minimum=i;
     }
 
@@ -290,7 +291,7 @@
     /// get back to the heap again.
     State state(const Item &item) const {
-      int i=iimap[item];
+      int i=_iim[item];
       if( i>=0 ) {
-        if ( container[i].in ) i=0;
+        if ( _data[i].in ) i=0;
         else i=-2;
       }
@@ -302,5 +303,5 @@
     /// Sets the state of the \c item in the heap. It can be used to
     /// manually clear the heap when it is important to achive the
-    /// better time complexity.
+    /// better time _complexity.
     /// \param i The item.
     /// \param st The state. It should not be \c IN_HEAP.
@@ -312,5 +313,5 @@
           erase(i);
         }
-        iimap[i] = st;
+        _iim[i] = st;
         break;
       case IN_HEAP:
@@ -323,5 +324,5 @@
     void balance() {
 
-      int maxdeg=int( std::floor( 2.08*log(double(container.size()))))+1;
+      int maxdeg=int( std::floor( 2.08*log(double(_data.size()))))+1;
 
       std::vector<int> A(maxdeg,-1);
@@ -331,6 +332,6 @@
        *We set minimum to this during balance().
        */
-      int anchor=container[minimum].left_neighbor;
-      int next=minimum;
+      int anchor=_data[_minimum].left_neighbor;
+      int next=_minimum;
       bool end=false;
 
@@ -338,9 +339,9 @@
         int active=next;
         if ( anchor==active ) end=true;
-        int d=container[active].degree;
-        next=container[active].right_neighbor;
+        int d=_data[active].degree;
+        next=_data[active].right_neighbor;
 
         while (A[d]!=-1) {
-          if( comp(container[active].prio, container[A[d]].prio) ) {
+          if( _comp(_data[active].prio, _data[A[d]].prio) ) {
             fuse(active,A[d]);
           } else {
@@ -355,11 +356,11 @@
 
 
-      while ( container[minimum].parent >=0 )
-        minimum=container[minimum].parent;
-      int s=minimum;
-      int m=minimum;
+      while ( _data[_minimum].parent >=0 )
+        _minimum=_data[_minimum].parent;
+      int s=_minimum;
+      int m=_minimum;
       do {
-        if ( comp(container[s].prio, container[minimum].prio) ) minimum=s;
-        s=container[s].right_neighbor;
+        if ( _comp(_data[s].prio, _data[_minimum].prio) ) _minimum=s;
+        s=_data[s].right_neighbor;
       } while ( s != m );
     }
@@ -368,6 +369,6 @@
       int s=c;
       do {
-        container[s].parent=-1;
-        s=container[s].right_neighbor;
+        _data[s].parent=-1;
+        s=_data[s].right_neighbor;
       } while ( s != c );
     }
@@ -377,10 +378,10 @@
        *Replacing a from the children of b.
        */
-      --container[b].degree;
-
-      if ( container[b].degree !=0 ) {
-        int child=container[b].child;
+      --_data[b].degree;
+
+      if ( _data[b].degree !=0 ) {
+        int child=_data[b].child;
         if ( child==a )
-          container[b].child=container[child].right_neighbor;
+          _data[b].child=_data[child].right_neighbor;
         unlace(a);
       }
@@ -388,19 +389,19 @@
 
       /*Lacing a to the roots.*/
-      int right=container[minimum].right_neighbor;
-      container[minimum].right_neighbor=a;
-      container[a].left_neighbor=minimum;
-      container[a].right_neighbor=right;
-      container[right].left_neighbor=a;
-
-      container[a].parent=-1;
-      container[a].marked=false;
+      int right=_data[_minimum].right_neighbor;
+      _data[_minimum].right_neighbor=a;
+      _data[a].left_neighbor=_minimum;
+      _data[a].right_neighbor=right;
+      _data[right].left_neighbor=a;
+
+      _data[a].parent=-1;
+      _data[a].marked=false;
     }
 
     void cascade(int a) {
-      if ( container[a].parent!=-1 ) {
-        int p=container[a].parent;
-
-        if ( container[a].marked==false ) container[a].marked=true;
+      if ( _data[a].parent!=-1 ) {
+        int p=_data[a].parent;
+
+        if ( _data[a].marked==false ) _data[a].marked=true;
         else {
           cut(a,p);
@@ -414,22 +415,22 @@
 
       /*Lacing b under a.*/
-      container[b].parent=a;
-
-      if (container[a].degree==0) {
-        container[b].left_neighbor=b;
-        container[b].right_neighbor=b;
-        container[a].child=b;
+      _data[b].parent=a;
+
+      if (_data[a].degree==0) {
+        _data[b].left_neighbor=b;
+        _data[b].right_neighbor=b;
+        _data[a].child=b;
       } else {
-        int child=container[a].child;
-        int last_child=container[child].left_neighbor;
-        container[child].left_neighbor=b;
-        container[b].right_neighbor=child;
-        container[last_child].right_neighbor=b;
-        container[b].left_neighbor=last_child;
-      }
-
-      ++container[a].degree;
-
-      container[b].marked=false;
+        int child=_data[a].child;
+        int last_child=_data[child].left_neighbor;
+        _data[child].left_neighbor=b;
+        _data[b].right_neighbor=child;
+        _data[last_child].right_neighbor=b;
+        _data[b].left_neighbor=last_child;
+      }
+
+      ++_data[a].degree;
+
+      _data[b].marked=false;
     }
 
@@ -438,12 +439,12 @@
      */
     void unlace(int a) {
-      int leftn=container[a].left_neighbor;
-      int rightn=container[a].right_neighbor;
-      container[leftn].right_neighbor=rightn;
-      container[rightn].left_neighbor=leftn;
-    }
-
-
-    class store {
+      int leftn=_data[a].left_neighbor;
+      int rightn=_data[a].right_neighbor;
+      _data[leftn].right_neighbor=rightn;
+      _data[rightn].left_neighbor=leftn;
+    }
+
+
+    class Store {
       friend class FibHeap;
 
@@ -458,5 +459,5 @@
       Prio prio;
 
-      store() : parent(-1), child(-1), degree(), marked(false), in(true) {}
+      Store() : parent(-1), child(-1), degree(), marked(false), in(true) {}
     };
   };
Index: lemon/radix_heap.h
===================================================================
--- lemon/radix_heap.h	(revision 728)
+++ lemon/radix_heap.h	(revision 730)
@@ -42,16 +42,16 @@
   /// item's priority.
   ///
-  /// \param _ItemIntMap A read and writable Item int map, used internally
+  /// \param IM A read and writable Item int map, used internally
   /// to handle the cross references.
   ///
   /// \see BinHeap
   /// \see Dijkstra
-  template <typename _ItemIntMap>
+  template <typename IM>
   class RadixHeap {
 
   public:
-    typedef typename _ItemIntMap::Key Item;
+    typedef typename IM::Key Item;
     typedef int Prio;
-    typedef _ItemIntMap ItemIntMap;
+    typedef IM ItemIntMap;
 
     /// \brief Exception thrown by RadixHeap.
@@ -100,5 +100,5 @@
     std::vector<RadixBox> boxes;
 
-    ItemIntMap &iim;
+    ItemIntMap &_iim;
 
 
@@ -108,5 +108,5 @@
     /// The constructor.
     ///
-    /// \param _iim It should be given to the constructor, since it is used
+    /// \param map It should be given to the constructor, since it is used
     /// internally to handle the cross references. The value of the map
     /// should be PRE_HEAP (-1) for each element.
@@ -114,6 +114,6 @@
     /// \param minimal The initial minimal value of the heap.
     /// \param capacity It determines the initial capacity of the heap.
-    RadixHeap(ItemIntMap &_iim, int minimal = 0, int capacity = 0)
-      : iim(_iim) {
+    RadixHeap(ItemIntMap &map, int minimal = 0, int capacity = 0)
+      : _iim(map) {
       boxes.push_back(RadixBox(minimal, 1));
       boxes.push_back(RadixBox(minimal + 1, 1));
@@ -269,5 +269,5 @@
           data[data[index].next].prev = index;
         }
-        iim[data[index].item] = index;
+        _iim[data[index].item] = index;
       }
       data.pop_back();
@@ -283,5 +283,5 @@
     void push(const Item &i, const Prio &p) {
       int n = data.size();
-      iim.set(i, n);
+      _iim.set(i, n);
       data.push_back(RadixItem(i, p));
       while (lower(boxes.size() - 1, p)) {
@@ -317,5 +317,5 @@
       moveDown();
       int index = boxes[0].first;
-      iim[data[index].item] = POST_HEAP;
+      _iim[data[index].item] = POST_HEAP;
       remove(index);
       relocate_last(index);
@@ -328,6 +328,6 @@
     /// \param i The item to erase.
     void erase(const Item &i) {
-      int index = iim[i];
-      iim[i] = POST_HEAP;
+      int index = _iim[i];
+      _iim[i] = POST_HEAP;
       remove(index);
       relocate_last(index);
@@ -340,5 +340,5 @@
     /// \param i The item.
     Prio operator[](const Item &i) const {
-      int idx = iim[i];
+      int idx = _iim[i];
       return data[idx].prio;
     }
@@ -353,5 +353,5 @@
     /// \param p The priority.
     void set(const Item &i, const Prio &p) {
-      int idx = iim[i];
+      int idx = _iim[i];
       if( idx < 0 ) {
         push(i, p);
@@ -375,5 +375,5 @@
     /// \param p The priority.
     void decrease(const Item &i, const Prio &p) {
-      int idx = iim[i];
+      int idx = _iim[i];
       data[idx].prio = p;
       bubble_down(idx);
@@ -387,5 +387,5 @@
     /// \param p The priority.
     void increase(const Item &i, const Prio &p) {
-      int idx = iim[i];
+      int idx = _iim[i];
       data[idx].prio = p;
       bubble_up(idx);
@@ -401,5 +401,5 @@
     /// \param i The item.
     State state(const Item &i) const {
-      int s = iim[i];
+      int s = _iim[i];
       if( s >= 0 ) s = 0;
       return State(s);
@@ -420,5 +420,5 @@
           erase(i);
         }
-        iim[i] = st;
+        _iim[i] = st;
         break;
       case IN_HEAP:
