Skip to content

Commit

Permalink
Whooops
Browse files Browse the repository at this point in the history
  • Loading branch information
budgetdevv committed Sep 24, 2024
1 parent 86714e3 commit 3732425
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Native/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ pub unsafe extern "C" fn tokenizer_encode_core(
{
let tokenizer = &*tokenizer_ptr;

let text = str::from_utf8_unchecked(text_buffer.as_slice());
let text = std::str::from_utf8_unchecked(text_buffer.as_slice());

let encoded_result = tokenizer.encode_fast(text, true);

Expand Down Expand Up @@ -318,7 +318,7 @@ pub unsafe extern "C" fn tokenizer_encode_batch_core(
let texts = text_buffers
.as_slice()
.iter()
.map(|text_buffer| str::from_utf8_unchecked(text_buffer.as_slice()))
.map(|text_buffer| std::str::from_utf8_unchecked(text_buffer.as_slice()))
.collect::<Vec<&str>>();

let encoded_result = tokenizer.encode_batch_fast(texts, true);
Expand Down

0 comments on commit 3732425

Please sign in to comment.