Skip to content

Commit

Permalink
trait ArrayDefault: Add docs.
Browse files Browse the repository at this point in the history
  • Loading branch information
kkysen committed Oct 16, 2023
1 parent 2074269 commit b98a747
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions include/common/bitdepth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,9 @@ impl_FromPrimitive!(isize => {, ...});
impl_FromPrimitive!(f32 => {, ...});
impl_FromPrimitive!(f64 => {, ...});

/// [`Default`] isn't `impl`emented for all arrays `[T; N]`
/// because they were implemented before `const` generics
/// and thus only for low values of `N`.
pub trait ArrayDefault {
fn default() -> Self;
}
Expand Down

0 comments on commit b98a747

Please sign in to comment.