Impl Debug for IgnoreDir.

This commit is contained in:
Andrew Gallant 2016-09-24 16:27:39 -04:00
parent 3b37f12ec0
commit 3bec8f3f0a

View File

@ -215,6 +215,7 @@ impl Ignore {
if !self.no_ignore { if !self.no_ignore {
for id in self.stack.iter().rev().filter_map(|id| id.as_ref()) { for id in self.stack.iter().rev().filter_map(|id| id.as_ref()) {
let mat = id.matched(path, is_dir); let mat = id.matched(path, is_dir);
// println!("{}, {:?}, {:?}, {:?}\n", path.display(), is_dir, mat, id);
if let Some(is_ignored) = self.ignore_match(path, mat) { if let Some(is_ignored) = self.ignore_match(path, mat) {
if is_ignored { if is_ignored {
return true; return true;
@ -257,6 +258,7 @@ impl Ignore {
/// IgnoreDir represents a set of ignore patterns retrieved from a single /// IgnoreDir represents a set of ignore patterns retrieved from a single
/// directory. /// directory.
#[derive(Debug)]
pub struct IgnoreDir { pub struct IgnoreDir {
/// The path to this directory as given. /// The path to this directory as given.
path: PathBuf, path: PathBuf,