Changeset d30a399 in git for Singular/links/ndbm.cc
- Timestamp:
- Oct 19, 2012, 9:59:20 AM (12 years ago)
- Branches:
- (u'spielwiese', 'fe61d9c35bf7c61f2b6cbf1b56e25e2f08d536cc')
- Children:
- 8710ff0734063b049b29453b8d06161041fffbc7b37b3984a12e1552c7bafc9fd5a7849240ea7980
- Parents:
- f2359093b446e8c68c3bda0f0484c4dbf7bd93a8
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Singular/links/ndbm.cc
rf23590 rd30a399 61 61 static datum makdatum(char buf[PBLKSIZ], int n); 62 62 static int finddatum(char buf[PBLKSIZ], datum item); 63 static long hashinc(register DBM *db, long hash);64 63 static long dcalchash(datum item); 65 64 static int delitem(char buf[PBLKSIZ], int n); … … 449 448 }; 450 449 451 static long hashinc(register DBM *db, long hash)452 {453 long bit;454 455 hash &= db->dbm_hmask;456 bit = db->dbm_hmask+1;457 for (;;)458 {459 bit >>= 1;460 if (bit == 0)461 return (0L);462 if ((hash & bit) == 0)463 return (hash | bit);464 hash &= ~bit;465 }466 }467 468 450 static long dcalchash(datum item) 469 451 {
Note: See TracChangeset
for help on using the changeset viewer.