Skip to content

Commit

Permalink
refactor(codegen): rename CodeBuffer::print_bytes_unchecked method
Browse files Browse the repository at this point in the history
  • Loading branch information
overlookmotel committed Oct 13, 2024
1 parent 782f0a7 commit ef3a2ce
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion crates/oxc_codegen/src/code_buffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ impl CodeBuffer {
///
/// [`print_byte_unchecked`]: CodeBuffer::print_byte_unchecked
#[inline]
pub unsafe fn print_unchecked<I>(&mut self, bytes: I)
pub unsafe fn print_bytes_unchecked<I>(&mut self, bytes: I)
where
I: IntoIterator<Item = u8>,
{
Expand Down
2 changes: 1 addition & 1 deletion crates/oxc_codegen/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ impl<'a> Codegen<'a> {
}
// SAFETY: this iterator only yields tabs, which are always valid ASCII characters.
unsafe {
self.code.print_unchecked(std::iter::repeat(b'\t').take(self.indent as usize));
self.code.print_bytes_unchecked(std::iter::repeat(b'\t').take(self.indent as usize));
}
}

Expand Down

0 comments on commit ef3a2ce

Please sign in to comment.