mirror of
https://gitee.com/openharmony/third_party_rust_nom
synced 2025-02-19 23:21:48 +00:00
fix failing test
This commit is contained in:
parent
c89e53ea69
commit
fa743698f7
@ -46,8 +46,8 @@ fn wrap_suffix(input: &Option<Vec<&[u8]>>) -> Option<String> {
|
||||
|
||||
#[cfg(feature = "alloc")]
|
||||
named!(parse_suffix<&[u8],Option<String>>,do_parse!(
|
||||
u: opt!(many1!(alt_complete!(
|
||||
tag!("%") | tag!("#") | tag!("@") | alpha
|
||||
u: opt!(many1!(alt!(
|
||||
complete!(tag!("%")) | complete!(tag!("#")) | complete!(tag!("@")) | complete!(alpha)
|
||||
))) >>
|
||||
(wrap_suffix(&u))
|
||||
));
|
||||
|
@ -142,8 +142,8 @@ named!(
|
||||
named!(issue_308(&str) -> bool,
|
||||
do_parse! (
|
||||
tag! ("foo") >>
|
||||
b: alt_complete! (
|
||||
map! (tag! ("1"), |_: &str|->bool {true}) |
|
||||
b: alt! (
|
||||
complete!(map! (tag! ("1"), |_: &str|->bool {true})) |
|
||||
value! (false)
|
||||
) >>
|
||||
(b) ));
|
||||
@ -254,7 +254,7 @@ mod issue_647 {
|
||||
}
|
||||
|
||||
fn list<'a,'b>(input: Input<'a>, _cs: &'b f64) -> Result<(Input<'a>,Vec<f64>), Err<(&'a [u8], ErrorKind)>> {
|
||||
separated_list_complete!(input, tag!(","),be_f64)
|
||||
separated_list!(input, complete!(tag!(",")), complete!(be_f64))
|
||||
}
|
||||
|
||||
named!(data<Input,Data>, map!(
|
||||
|
Loading…
x
Reference in New Issue
Block a user