Skip to content

Commit ef4a37e

Browse files
committed
fix: invalid type bug in Windows
1 parent 8d012c2 commit ef4a37e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

llama-cpp-2/src/token_type.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ impl TryFrom<llama_cpp_sys_2::llama_token_type> for LlamaTokenAttrs {
4242
type Error = LlamaTokenTypeFromIntError;
4343

4444
fn try_from(value: llama_cpp_sys_2::llama_vocab_type) -> Result<Self, Self::Error> {
45-
Ok(Self(BitFlags::from_bits(value).map_err(|e| {
45+
Ok(Self(BitFlags::from_bits(value as _).map_err(|e| {
4646
LlamaTokenTypeFromIntError::UnknownValue(e.invalid_bits())
4747
})?))
4848
}

0 commit comments

Comments
 (0)