Commit 1c552a4a authored by MovingtoMars's avatar MovingtoMars

replace .len() == 0 with .is_empty()

parent 77f9c2c9
......@@ -15,7 +15,7 @@ fn main() {
loop {
let res = con.read_line("[prompt]$ ", &mut |_| {}).unwrap();
if res.len() == 0 {
if res.is_empty() {
break;
}
......
......@@ -34,7 +34,7 @@ fn main() {
})
.unwrap();
if res.len() == 0 {
if res.is_empty() {
break;
}
con.history.push(res.into());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment