@@ -207,7 +207,7 @@ pub fn StoreLookaheadThenStore<T: AnyHasher>(hasher: &mut T, size: usize, dict:
207
207
pub trait BasicHashComputer {
208
208
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 ;
209
209
fn BUCKET_BITS ( & self ) -> i32 ;
210
- fn USE_DICTIONARY ( & self ) -> i32 ;
210
+ fn use_dictionary ( & self ) -> bool ;
211
211
fn BUCKET_SWEEP ( & self ) -> i32 ;
212
212
}
213
213
pub struct BasicHasher < Buckets : SliceWrapperMut < u32 > + SliceWrapper < u32 > + BasicHashComputer > {
@@ -431,7 +431,7 @@ impl<T: SliceWrapperMut<u32> + SliceWrapper<u32> + BasicHashComputer> AnyHasher
431
431
}
432
432
}
433
433
}
434
- if dictionary. is_some ( ) && self . buckets_ . USE_DICTIONARY ( ) != 0 && !is_match_found {
434
+ if dictionary. is_some ( ) && self . buckets_ . use_dictionary ( ) && !is_match_found {
435
435
is_match_found = SearchInStaticDictionary (
436
436
dictionary. unwrap ( ) ,
437
437
dictionary_hash,
@@ -462,8 +462,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H2Sub<AllocU32> {
462
462
fn BUCKET_SWEEP ( & self ) -> i32 {
463
463
1
464
464
}
465
- fn USE_DICTIONARY ( & self ) -> i32 {
466
- 1
465
+ fn use_dictionary ( & self ) -> bool {
466
+ true
467
467
}
468
468
}
469
469
impl < AllocU32 : alloc:: Allocator < u32 > > SliceWrapperMut < u32 > for H2Sub < AllocU32 > {
@@ -496,8 +496,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H3Sub<AllocU32> {
496
496
fn BUCKET_SWEEP ( & self ) -> i32 {
497
497
2
498
498
}
499
- fn USE_DICTIONARY ( & self ) -> i32 {
500
- 0
499
+ fn use_dictionary ( & self ) -> bool {
500
+ false
501
501
}
502
502
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
503
503
let h: u64 =
@@ -515,8 +515,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H4Sub<AllocU32> {
515
515
fn BUCKET_SWEEP ( & self ) -> i32 {
516
516
4
517
517
}
518
- fn USE_DICTIONARY ( & self ) -> i32 {
519
- 1
518
+ fn use_dictionary ( & self ) -> bool {
519
+ true
520
520
}
521
521
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
522
522
let h: u64 =
@@ -544,8 +544,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H54Sub<AllocU32> {
544
544
fn BUCKET_SWEEP ( & self ) -> i32 {
545
545
4
546
546
}
547
- fn USE_DICTIONARY ( & self ) -> i32 {
548
- 0
547
+ fn use_dictionary ( & self ) -> bool {
548
+ false
549
549
}
550
550
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
551
551
let h: u64 =
0 commit comments