• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 use {
2     crate::{Arbitrary, Result, Unstructured},
3     std::{ffi::OsString, path::PathBuf},
4 };
5 
6 impl<'a> Arbitrary<'a> for PathBuf {
arbitrary(u: &mut Unstructured<'a>) -> Result<Self>7     fn arbitrary(u: &mut Unstructured<'a>) -> Result<Self> {
8         <OsString as Arbitrary>::arbitrary(u).map(From::from)
9     }
10 
11     #[inline]
size_hint(depth: usize) -> (usize, Option<usize>)12     fn size_hint(depth: usize) -> (usize, Option<usize>) {
13         <OsString as Arbitrary>::size_hint(depth)
14     }
15 }
16