smol-bytes 0.1.8

High-performance, clone-efficient byte buffers optimized for small data.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
use std::string::String;

use super::*;

impl<'a, S> ::arbitrary::Arbitrary<'a> for Utf8Bytes<S>
where
  RawBytes<S>: ImmutableStorage,
{
  fn arbitrary(u: &mut ::arbitrary::Unstructured<'a>) -> ::arbitrary::Result<Self> {
    let s = String::arbitrary(u)?;
    Ok(Self::from(s))
  }
}