summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Gallant <jamslam@gmail.com>2024-01-06 12:25:06 -0500
committerAndrew Gallant <jamslam@gmail.com>2024-01-06 12:25:06 -0500
commit67dd809a8097923a721305ce0632a9fb9f19cb57 (patch)
tree7acd393a3a9d0b3f000c34980c204ab4e7c7f544
parente0a85678e112759f56f9e07d04a29f2eed6eb348 (diff)
ignore: add some 'allow(dead_code)' annotations
I don't usually like doing this and would prefer to just delete unused code, but I don't have the context required to understand why this code is unused. A refresh of this crate is on the (distant) horizon, so I'll just leave these here for now to squash the warnings.
-rw-r--r--crates/ignore/src/dir.rs2
-rw-r--r--crates/ignore/src/overrides.rs2
2 files changed, 4 insertions, 0 deletions
diff --git a/crates/ignore/src/dir.rs b/crates/ignore/src/dir.rs
index 51fc813e..7f8ff103 100644
--- a/crates/ignore/src/dir.rs
+++ b/crates/ignore/src/dir.rs
@@ -34,11 +34,13 @@ use crate::{
/// IgnoreMatch represents information about where a match came from when using
/// the `Ignore` matcher.
#[derive(Clone, Debug)]
+#[allow(dead_code)]
pub(crate) struct IgnoreMatch<'a>(IgnoreMatchInner<'a>);
/// IgnoreMatchInner describes precisely where the match information came from.
/// This is private to allow expansion to more matchers in the future.
#[derive(Clone, Debug)]
+#[allow(dead_code)]
enum IgnoreMatchInner<'a> {
Override(overrides::Glob<'a>),
Gitignore(&'a gitignore::Glob),
diff --git a/crates/ignore/src/overrides.rs b/crates/ignore/src/overrides.rs
index fd8af95d..1b02b4d4 100644
--- a/crates/ignore/src/overrides.rs
+++ b/crates/ignore/src/overrides.rs
@@ -23,9 +23,11 @@ use crate::{
/// The lifetime `'a` refers to the lifetime of the matcher that produced
/// this glob.
#[derive(Clone, Debug)]
+#[allow(dead_code)]
pub struct Glob<'a>(GlobInner<'a>);
#[derive(Clone, Debug)]
+#[allow(dead_code)]
enum GlobInner<'a> {
/// No glob matched, but the file path should still be ignored.
UnmatchedIgnore,