diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2019-03-05 16:26:42 -0800 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2019-03-05 16:26:42 -0800 |
commit | 3cce04c62daf75aaf156246b6fc0498f0106f76d (patch) | |
tree | 4f56e7fd2acd09c5e6dd2a199612f73fab14b98a /src/misc/extra | |
parent | f657d9a7e6aedbb33063d050bc65d8eb3c95098b (diff) | |
download | abc-3cce04c62daf75aaf156246b6fc0498f0106f76d.tar.gz abc-3cce04c62daf75aaf156246b6fc0498f0106f76d.tar.bz2 abc-3cce04c62daf75aaf156246b6fc0498f0106f76d.zip |
Fixing some more warnings by adding cast from 'int' to 'size_t'.
Diffstat (limited to 'src/misc/extra')
-rw-r--r-- | src/misc/extra/extra.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/misc/extra/extra.h b/src/misc/extra/extra.h index 6c0fd74a..e8afebd8 100644 --- a/src/misc/extra/extra.h +++ b/src/misc/extra/extra.h @@ -249,9 +249,9 @@ static inline void Extra_ProgressBarUpdate( ProgressBar * p, int nItemsCur, char static inline int Extra_BitWordNum( int nBits ) { return nBits/(8*sizeof(unsigned)) + ((nBits%(8*sizeof(unsigned))) > 0); } static inline int Extra_TruthWordNum( int nVars ) { return nVars <= 5 ? 1 : (1 << (nVars - 5)); } -static inline void Extra_TruthSetBit( unsigned * p, int Bit ) { p[Bit>>5] |= (1<<(Bit & 31)); } -static inline void Extra_TruthXorBit( unsigned * p, int Bit ) { p[Bit>>5] ^= (1<<(Bit & 31)); } -static inline int Extra_TruthHasBit( unsigned * p, int Bit ) { return (p[Bit>>5] & (1<<(Bit & 31))) > 0; } +static inline void Extra_TruthSetBit( unsigned * p, int Bit ) { p[Bit>>5] |= (unsigned)(1<<(Bit & 31)); } +static inline void Extra_TruthXorBit( unsigned * p, int Bit ) { p[Bit>>5] ^= (unsigned)(1<<(Bit & 31)); } +static inline int Extra_TruthHasBit( unsigned * p, int Bit ) { return (p[Bit>>5] & (unsigned)(1<<(Bit & 31))) > 0; } static inline int Extra_WordCountOnes( unsigned uWord ) { |