Skip to content

Commit cd1b678

Browse files
committed
zdict.rs: remove casts
1 parent b3843be commit cd1b678

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

lib/dictBuilder/zdict.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -190,13 +190,12 @@ unsafe fn ZDICT_analyzePos(
190190
let mut u: u32 = 0;
191191
let mut patternEnd = 6u32;
192192
while MEM_read16(b.add(pos).offset(patternEnd as isize) as *const core::ffi::c_void)
193-
as core::ffi::c_int
194-
== pattern16 as core::ffi::c_int
193+
== pattern16
195194
{
196195
patternEnd = patternEnd.wrapping_add(2);
197196
}
198-
if *b.add(pos.wrapping_add(patternEnd as size_t)) as core::ffi::c_int
199-
== *b.add(pos.wrapping_add(patternEnd as size_t).wrapping_sub(1)) as core::ffi::c_int
197+
if *b.add(pos.wrapping_add(patternEnd as size_t))
198+
== *b.add(pos.wrapping_add(patternEnd as size_t).wrapping_sub(1))
200199
{
201200
patternEnd = patternEnd.wrapping_add(1);
202201
}

0 commit comments

Comments
 (0)