@@ -214,7 +214,7 @@ pub fn StoreLookaheadThenStore<T: AnyHasher>(hasher: &mut T, size: usize, dict:
214
214
pub trait BasicHashComputer {
215
215
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 ;
216
216
fn BUCKET_BITS ( & self ) -> i32 ;
217
- fn USE_DICTIONARY ( & self ) -> i32 ;
217
+ fn use_dictionary ( & self ) -> bool ;
218
218
fn BUCKET_SWEEP ( & self ) -> i32 ;
219
219
}
220
220
pub struct BasicHasher < Buckets : SliceWrapperMut < u32 > + SliceWrapper < u32 > + BasicHashComputer > {
@@ -438,7 +438,7 @@ impl<T: SliceWrapperMut<u32> + SliceWrapper<u32> + BasicHashComputer> AnyHasher
438
438
}
439
439
}
440
440
}
441
- if dictionary. is_some ( ) && self . buckets_ . USE_DICTIONARY ( ) != 0 && !is_match_found {
441
+ if dictionary. is_some ( ) && self . buckets_ . use_dictionary ( ) && !is_match_found {
442
442
is_match_found = SearchInStaticDictionary (
443
443
dictionary. unwrap ( ) ,
444
444
dictionary_hash,
@@ -469,8 +469,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H2Sub<AllocU32> {
469
469
fn BUCKET_SWEEP ( & self ) -> i32 {
470
470
1
471
471
}
472
- fn USE_DICTIONARY ( & self ) -> i32 {
473
- 1
472
+ fn use_dictionary ( & self ) -> bool {
473
+ true
474
474
}
475
475
}
476
476
impl < AllocU32 : alloc:: Allocator < u32 > > SliceWrapperMut < u32 > for H2Sub < AllocU32 > {
@@ -503,8 +503,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H3Sub<AllocU32> {
503
503
fn BUCKET_SWEEP ( & self ) -> i32 {
504
504
2
505
505
}
506
- fn USE_DICTIONARY ( & self ) -> i32 {
507
- 0
506
+ fn use_dictionary ( & self ) -> bool {
507
+ false
508
508
}
509
509
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
510
510
let h: u64 =
@@ -522,8 +522,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H4Sub<AllocU32> {
522
522
fn BUCKET_SWEEP ( & self ) -> i32 {
523
523
4
524
524
}
525
- fn USE_DICTIONARY ( & self ) -> i32 {
526
- 1
525
+ fn use_dictionary ( & self ) -> bool {
526
+ true
527
527
}
528
528
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
529
529
let h: u64 =
@@ -551,8 +551,8 @@ impl<AllocU32: alloc::Allocator<u32>> BasicHashComputer for H54Sub<AllocU32> {
551
551
fn BUCKET_SWEEP ( & self ) -> i32 {
552
552
4
553
553
}
554
- fn USE_DICTIONARY ( & self ) -> i32 {
555
- 0
554
+ fn use_dictionary ( & self ) -> bool {
555
+ false
556
556
}
557
557
fn HashBytes ( & self , data : & [ u8 ] ) -> u32 {
558
558
let h: u64 =
0 commit comments