deps: update to thread_local 1.0

We also update the pcre2 and regex dependencies, which removes any other
lingering uses of thread_local 0.3.
This commit is contained in:
Andrew Gallant
2020-01-09 20:58:28 -05:00
parent bd7a42602f
commit cb2f6ddc61
6 changed files with 23 additions and 23 deletions

View File

@@ -25,7 +25,7 @@ log = "0.4.5"
memchr = "2.1"
regex = "1.1"
same-file = "1.0.4"
thread_local = "0.3.6"
thread_local = "1"
walkdir = "2.2.7"
[target.'cfg(windows)'.dependencies.winapi-util]

View File

@@ -249,7 +249,7 @@ impl Gitignore {
return Match::None;
}
let path = path.as_ref();
let _matches = self.matches.as_ref().unwrap().get_default();
let _matches = self.matches.as_ref().unwrap().get_or_default();
let mut matches = _matches.borrow_mut();
let candidate = Candidate::new(path);
self.set.matches_candidate_into(&candidate, &mut *matches);

View File

@@ -515,7 +515,7 @@ impl Types {
return Match::None;
}
};
let mut matches = self.matches.get_default().borrow_mut();
let mut matches = self.matches.get_or_default().borrow_mut();
self.set.matches_into(name, &mut *matches);
// The highest precedent match is the last one.
if let Some(&i) = matches.last() {