feat: Only flycheck workspace that belongs to saved file

This commit is contained in:
Lukas Wirth 2022-07-18 20:30:07 +02:00
parent ea416175d5
commit a63b5d3c84
3 changed files with 70 additions and 7 deletions

View file

@ -103,6 +103,14 @@ impl AsRef<Path> for AbsPath {
}
}
impl ToOwned for AbsPath {
type Owned = AbsPathBuf;
fn to_owned(&self) -> Self::Owned {
AbsPathBuf(self.0.to_owned())
}
}
impl<'a> TryFrom<&'a Path> for &'a AbsPath {
type Error = &'a Path;
fn try_from(path: &'a Path) -> Result<&'a AbsPath, &'a Path> {