COIN-OR::LEMON - Graph Library

Changeset 2050:d9a221218ea4 in lemon-0.x for lemon/bin_heap.h


Ignore:
Timestamp:
04/14/06 20:05:02 (14 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2693
Message:

Changing the mining of the clear in heaps
It does not touch the heap cross ref. It is
sometimes more clean useable and more efficient

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/bin_heap.h

    r1956 r2050  
    113113    /// \brief Make empty this heap.
    114114    ///
    115     /// Make empty this heap.
     115    /// Make empty this heap. It does not change the cross reference map.
     116    /// If you want to reuse what is not surely empty you should first clear
     117    /// the heap and after that you should set the cross reference map for
     118    /// each item to \c PRE_HEAP.
    116119    void clear() {
    117       for (int i = 0; i < (int)data.size(); ++i) {
    118         iim.set(data[i].first, POST_HEAP);
    119       }
    120120      data.clear();
    121121    }
Note: See TracChangeset for help on using the changeset viewer.