projects
/
Mitarbeiter
/
Tim-Zeitz
/
stud-rust-base.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
refactor
[Mitarbeiter/Tim-Zeitz/stud-rust-base.git]
/
src
/
bin
/
decode_vector.rs
diff --git
a/src/bin/decode_vector.rs
b/src/bin/decode_vector.rs
index 4dca2e7ba46cd023de48a1d080d87bd109710c0d..68d5bb24f59de11de27a8d9d24e29849713bead8 100644
(file)
--- a/
src/bin/decode_vector.rs
+++ b/
src/bin/decode_vector.rs
@@
-2,10
+2,7
@@
use stud_rust_base::{io::*, cli::CliErr};
use std::{env, error::Error};
fn main() -> Result<(), Box<dyn Error>> {
use std::{env, error::Error};
fn main() -> Result<(), Box<dyn Error>> {
- let mut args = env::args();
- args.next();
-
- match &args.collect::<Vec<String>>()[..] {
+ match &env::args().skip(1).collect::<Vec<String>>()[..] {
[data_type, input] => {
match data_type.as_ref() {
"i8" => { print_values(Vec::<i8>::load_from(input)?); Ok(()) },
[data_type, input] => {
match data_type.as_ref() {
"i8" => { print_values(Vec::<i8>::load_from(input)?); Ok(()) },