parser : suppression bug où le point virgule ne fonctionne pas s'il n'est pas précédé d'une espace

This commit is contained in:
Ahurac 2024-04-15 11:11:11 +02:00
parent 47c560c03a
commit 7fa67bd034

View file

@ -43,7 +43,13 @@ fn parse_main(characters: &mut Vec<char>, current_arg: &mut String) -> Vec<Strin
argv argv
} else if current_char == ';' { } else if current_char == ';' {
vec![] let mut argv: Vec<String> = vec![];
if !current_arg.is_empty() {
argv.push(current_arg.clone());
}
argv
} else { } else {
current_arg.push(current_char); current_arg.push(current_char);
parse_main(characters, current_arg) parse_main(characters, current_arg)