Skip to main content

split_repl_words

Function split_repl_words 

Source
pub fn split_repl_words(line: &str) -> Result<Vec<String>, String>
Expand description

Splits a line into words, shell-style: whitespace separates words, "..." and '...' group them, and a backslash escapes the next character (outside single quotes). Unlike a real shell there is no comment syntax, so #hashtag is an ordinary word.