Remove Copy from PushBytesError

The `PushBytesError` is the only error type in the codebase to derive
`Copy`. Without thinking too hard this is unusual - remove it.

Thinking a bit harder it makes the code less maintainable because
we must commit to implementing `Copy`.
This commit is contained in:
Tobin C. Harding 2025-01-08 10:30:03 +11:00
parent 4ade08c755
commit 0870cd1660
No known key found for this signature in database
GPG Key ID: 40BF9E4C269D6607
1 changed files with 2 additions and 2 deletions

View File

@ -413,7 +413,7 @@ mod error {
/// Error returned on attempt to create too large `PushBytes`.
#[allow(unused)]
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
#[derive(Debug, Clone, PartialEq, Eq)]
pub struct PushBytesError {
never: core::convert::Infallible,
}
@ -435,7 +435,7 @@ mod error {
use core::fmt;
/// Error returned on attempt to create too large `PushBytes`.
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
#[derive(Debug, Clone, PartialEq, Eq)]
pub struct PushBytesError {
/// How long the input was.
pub(super) len: usize,