mirror of
https://github.com/mii443/tokenizers.git
synced 2025-09-01 14:59:20 +00:00
Hotfix Python bindings for 32-bit systems
This commit is contained in:
@ -61,7 +61,8 @@ impl PyMappingProtocol for IndexableString {
|
|||||||
}?;
|
}?;
|
||||||
|
|
||||||
// Find out range from the slice
|
// Find out range from the slice
|
||||||
let PySliceIndices { start, stop, .. } = slice.indices(self.s.len() as i64)?;
|
let len: std::os::raw::c_long = (self.s.len() as i32) as _;
|
||||||
|
let PySliceIndices { start, stop, .. } = slice.indices(len)?;
|
||||||
let range = start as usize..stop as usize;
|
let range = start as usize..stop as usize;
|
||||||
|
|
||||||
// Get the range from the relevant string
|
// Get the range from the relevant string
|
||||||
|
Reference in New Issue
Block a user