Changeset d4932a in git for factory/canonicalform.cc


Ignore:
Timestamp:
Jun 25, 2010, 4:25:41 PM (14 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'fieker-DuVal', '117eb8c30fc9e991c4decca4832b1d19036c4c65')(u'spielwiese', 'd25190065115c859833252500a64cfb7b11e3a50')
Children:
cedebce21b0dc12678683874874cce5b35d8c23d
Parents:
9919421a652e331106b0f71cb3996f006942bc13
Message:
fix log(int) -> ilog2

git-svn-id: file:///usr/local/Singular/svn/trunk@12924 2c84dea3-7e68-4137-9b89-c4e89433aadc
File:
1 edited

Legend:

Unmodified
Added
Removed
  • factory/canonicalform.cc

    r9919421 rd4932a  
    12041204CanonicalForm::ilog2 () const
    12051205{
    1206     if ( is_imm( value ) ) {
     1206    if ( is_imm( value ) )
     1207    {
    12071208        ASSERT( is_imm( value ) == INTMARK, "ilog2() not implemented" );
    12081209        int a = imm2int( value );
    12091210        ASSERT( a > 0, "arg to ilog2() less or equal zero" );
    1210         int n = -1;
    1211         while ( a != 0 ) {
    1212             n++;
    1213             a /= 2;
    1214         }
    1215         return n;
     1211        return ::ilog2(a);
    12161212    }
    12171213    else
Note: See TracChangeset for help on using the changeset viewer.