1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-27 02:57:44 +00:00

Use an iterator over OsString for uumain()

Additionally, restructure `uname` so that we don't need to find the
iterator's length.
This commit is contained in:
Alex Lyon 2020-06-16 03:10:21 -05:00
parent 1309972149
commit 110d6844ad
No known key found for this signature in database
GPG key ID: 15B1C566BEF7A2D8
96 changed files with 330 additions and 178 deletions

View file

@ -43,10 +43,10 @@ pub fn main() {
let mut tf = File::create(Path::new(&out_dir).join("test_modules.rs")).unwrap();
mf.write_all(
"type UtilityMap = HashMap<&'static str, fn(Vec<String>) -> i32>;\n\
"type UtilityMap<T> = HashMap<&'static str, fn(T) -> i32>;\n\
\n\
fn util_map() -> UtilityMap {\n\
\tlet mut map: UtilityMap = HashMap::new();\n\
fn util_map<T: uucore::Args>() -> UtilityMap<T> {\n\
\tlet mut map = UtilityMap::new();\n\
"
.as_bytes(),
)