oven-sh/bun · error · OverflowError

Overflow

Error message

Overflow

What it means

Error "Overflow" thrown in oven-sh/bun.

Source

Thrown at src/bun_core/bounded_array.rs:19

//! A structure with an array and a length, that can be used as a slice.
//!
//! Useful to pass around small arrays whose exact size is only known at
//! runtime, but whose maximum size is known at compile time, without requiring
//! an `Allocator`.
//!
//! ```ignore
//! let actual_size = 32;
//! let mut a = BoundedArray::<u8, 64>::init(actual_size)?;
//! let slice = a.slice(); // a slice of the 64-byte array
//! let a_clone = a.clone(); // creates a copy - the structure doesn't use any internal pointers
//! ```

use core::mem::MaybeUninit;

/// `error{Overflow}`
#[derive(thiserror::Error, strum::IntoStaticStr, Debug, Copy, Clone, Eq, PartialEq)]
pub enum OverflowError {
    #[error("Overflow")]
    Overflow,
}

/// A structure with an array and a length, that can be used as a slice.
///
/// Useful to pass around small arrays whose exact size is only known at
/// runtime, but whose maximum size is known at compile time, without requiring
/// an `Allocator`.
pub type BoundedArray<T, const BUFFER_CAPACITY: usize> = BoundedArrayAligned<T, BUFFER_CAPACITY>;
// The natural alignment of `[T; N]` is already `align_of::<T>()`, so the alias is
// transparent. The explicit `alignment` const-param is dropped (see below).

/// A structure with an array, length and alignment, that can be used as a
/// slice.
///
/// Useful to pass around small explicitly-aligned arrays whose exact size is
/// only known at runtime, but whose maximum size is known at compile time, without
/// requiring an `Allocator`.

View on GitHub (pinned to 8c5296ac45)

When it happens

Trigger: Thrown at src/bun_core/bounded_array.rs:19 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of oven-sh/bun@8c5296ac45 (2026-08-16). Data as JSON: /api/errors/cea808dcd3a157d6. Report an issue: GitHub.