1 use std::{collections::HashSet, path::PathBuf}; 2 3 use crate::utils::FileUtils; 4 setup_common_files(files: &mut HashSet<PathBuf>)5pub(super) fn setup_common_files(files: &mut HashSet<PathBuf>) { 6 const DIRS: [&str; 3] = ["src/common", "src/debug/traceback", "src/libs"]; 7 DIRS.iter().for_each(|dir| { 8 FileUtils::list_all_files(&dir.into(), Some("c"), true) 9 .into_iter() 10 .for_each(|f| { 11 files.insert(f); 12 }); 13 }); 14 } 15 setup_common_include_dir(include_dirs: &mut HashSet<PathBuf>)16pub(super) fn setup_common_include_dir(include_dirs: &mut HashSet<PathBuf>) { 17 const DIRS: [&str; 3] = ["src/include", "src/common", "src"]; 18 DIRS.iter().for_each(|dir| { 19 include_dirs.insert(dir.into()); 20 }); 21 } 22