2018-07-18 10:42:52 +03:00
|
|
|
/*! A parser module for user commands passed through the Ex mode.
|
|
|
|
*/
|
2018-07-17 17:16:16 +03:00
|
|
|
use std;
|
2018-07-24 20:20:32 +03:00
|
|
|
use nom::{digit, };
|
2018-07-17 17:16:16 +03:00
|
|
|
|
|
|
|
|
|
|
|
named!(usize_c<usize>,
|
2018-07-18 10:42:52 +03:00
|
|
|
map_res!(map_res!(ws!(digit), std::str::from_utf8), std::str::FromStr::from_str));
|
2018-07-17 17:16:16 +03:00
|
|
|
|
|
|
|
named!(pub goto<usize>,
|
2018-07-21 11:20:13 +03:00
|
|
|
preceded!(tag!("b "),
|
|
|
|
call!(usize_c))
|
|
|
|
);
|
|
|
|
|
2018-07-24 20:20:32 +03:00
|
|
|
/*
|
2018-07-21 11:20:13 +03:00
|
|
|
named!(pub sort<&str>,
|
|
|
|
preceded!(tag!("sort "),
|
|
|
|
map_res!(call!(alpha), std::str::from_utf8))
|
2018-07-18 10:42:52 +03:00
|
|
|
);
|
2018-07-24 20:20:32 +03:00
|
|
|
*/
|