fail in case nothing to run was found

This commit is contained in:
Guillaume Gomez 2017-07-10 16:27:46 +02:00 committed by Mark Simulacrum
parent f19728f4c7
commit 828b661ae0

View File

@ -113,11 +113,16 @@ macro_rules! check {
})+
} else {
for path in paths {
let mut attempted_run = false;
$({
if <$rule>::should_run($self, path) {
attempted_run = true;
$self.maybe_run::<$rule>(Some(path));
}
})+
if !attempted_run {
eprintln!("Warning: no rules matched {}.", path.display());
}
}
}
}};