(&self)
| 193 | let path = path.into(); |
| 194 | validate(&path)?; |
| 195 | Ok(Self(Cow::Owned(path))) |
| 196 | } |
| 197 | |
| 198 | pub fn as_res_path(&self) -> &ResPath { |
| 199 | // SAFETY: ResPathBuf constructors validate owned and borrowed storage. |
| 200 | unsafe { ResPath::new_unchecked_borrowed(&self.0) } |
no test coverage detected