COIN-OR::LEMON - Graph Library

Changeset 2078:123f08422c14 in lemon-0.x for lemon


Ignore:
Timestamp:
05/12/06 11:54:58 (13 years ago)
Author:
Balazs Dezso
Branch:
default
Phase:
public
Convert:
svn:c9d7d8f5-90d6-0310-b91f-818b3a526b0e/lemon/trunk@2741
Message:

Revised Compile Time Arithmetic

File:
1 edited

Legend:

Unmodified
Added
Removed
  • lemon/bits/utility.h

    r2077 r2078  
    107107  };
    108108
    109   template <bool sless, bool sequal, bool bless>
    110   struct CTLessImpl {
    111    static const bool value =
    112    CTOr<sless, CTAnd<sequal, bless>::value>::value;
    113   };
    114109
    115110  template <int left, int right>
    116111  struct CTLess {
    117     static const bool value =
    118     CTLessImpl<CTLess<left >> 1, right >> 1>::value,
    119                CTEqual<left >> 1, right >> 1>::value,
    120                CTLess<left & 1, right & 1>::value >::value;
     112    static const bool value = left < right;
    121113  };
    122114
Note: See TracChangeset for help on using the changeset viewer.