prevent generating duplicate stubs

This commit is contained in:
tinaun 2018-01-01 19:32:44 -05:00
parent 46cd410381
commit 5c25b0c594
2 changed files with 4 additions and 6 deletions

View File

@ -87,7 +87,7 @@ pub fn check(path: &path::Path, bad: &mut bool) {
// Library features
let lang_features = collect_lang_features(path);
let lib_features = collect_lib_features(path).iter().filter(|(name, _) {
let lib_features = collect_lib_features(path).into_iter().filter(|&(ref name, _)| {
!lang_features.contains_key(name)
}).collect();

View File

@ -129,11 +129,9 @@ fn main() {
let dest_path = Path::new(&dest_path_str).join("src");
let lang_features = collect_lang_features(src_path);
let lib_features = collect_lib_features(src_path)
.iter()
.filter(|(name, _) {
!lang_features.contains_key(name)
}).collect();
let lib_features = collect_lib_features(src_path).into_iter().filter(|&(ref name, _)| {
!lang_features.contains_key(name)
}).collect();
let doc_src_path = src_path.join(PATH_STR);