docs(codegen): improve doc comments for CodeBuffer (#6511)

This commit is contained in:
overlookmotel 2024-10-13 12:21:39 +00:00
parent e7f3e28076
commit 235d357600

View file

@ -61,7 +61,6 @@ impl CodeBuffer {
/// minimum *capacity* specified, the buffer will have a zero *length*. /// minimum *capacity* specified, the buffer will have a zero *length*.
/// ///
/// # Panics /// # Panics
///
/// Panics if the new capacity exceeds `isize::MAX` bytes. /// Panics if the new capacity exceeds `isize::MAX` bytes.
#[inline] #[inline]
pub fn with_capacity(capacity: usize) -> Self { pub fn with_capacity(capacity: usize) -> Self {
@ -100,7 +99,6 @@ impl CodeBuffer {
/// Does nothing if capacity is already sufficient. /// Does nothing if capacity is already sufficient.
/// ///
/// # Panics /// # Panics
///
/// Panics if the new capacity exceeds `isize::MAX` bytes. /// Panics if the new capacity exceeds `isize::MAX` bytes.
/// ///
/// # Example /// # Example
@ -139,7 +137,7 @@ impl CodeBuffer {
/// Push a single ASCII byte into the buffer. /// Push a single ASCII byte into the buffer.
/// ///
/// # Panics /// # Panics
/// If `byte` is not an ASCII byte (`0 - 0x7F`). /// Panics if `byte` is not an ASCII byte (`0 - 0x7F`).
/// ///
/// # Example /// # Example
/// ``` /// ```