Skip to content

Commit

Permalink
Clippy.
Browse files Browse the repository at this point in the history
  • Loading branch information
Narsil committed Nov 15, 2024
1 parent d35b966 commit 70c4f6b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tokenizers/src/tokenizer/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1070,7 +1070,7 @@ where
/// See [`DecodeStream`]
pub fn step(&mut self, id: u32) -> Result<Option<String>> {
step_decode_stream(
&self.tokenizer,
self.tokenizer,
id,
self.skip_special_tokens,
&mut self.ids,
Expand Down Expand Up @@ -1107,7 +1107,7 @@ where
let new_text = &string[prefix.len()..].to_string();
let new_prefix_index = ids.len() - *prefix_index;
*ids = ids.drain(*read_index..).collect();
*prefix = tokenizer.decode(&ids, skip_special_tokens)?;
*prefix = tokenizer.decode(ids, skip_special_tokens)?;
*read_index = *prefix_index;
*prefix_index = new_prefix_index;
Ok(Some(new_text.to_string()))
Expand Down

0 comments on commit 70c4f6b

Please sign in to comment.