Skip to content

Commit

Permalink
Merge branch 'GuillaumeGomez-char-doc-examples'
Browse files Browse the repository at this point in the history
  • Loading branch information
Geal committed Apr 25, 2019
2 parents b027224 + a1b82de commit 2ad6509
Show file tree
Hide file tree
Showing 3 changed files with 569 additions and 90 deletions.
8 changes: 4 additions & 4 deletions src/bytes/macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,11 @@ macro_rules! is_a (
/// # Example
/// ```
/// # #[macro_use] extern crate nom;
/// # use nom::character::complete::alpha;
/// # use nom::character::complete::digit;
/// # fn main() {
/// named!(esc, escaped!(call!(alpha), '\\', one_of!("\"n\\")));
/// assert_eq!(esc(&b"abcd;"[..]), Ok((&b";"[..], &b"abcd"[..])));
/// assert_eq!(esc(&b"ab\\\"cd;"[..]), Ok((&b";"[..], &b"ab\\\"cd"[..])));
/// named!(esc, escaped!(call!(digit), '\\', one_of!("\"n\\")));
/// assert_eq!(esc(&b"123;"[..]), Ok((&b";"[..], &b"123"[..])));
/// assert_eq!(esc(&b"12\\\"34;"[..]), Ok((&b";"[..], &b"12\\\"34"[..])));
/// # }
/// ```
#[macro_export(local_inner_macros)]
Expand Down
Loading

0 comments on commit 2ad6509

Please sign in to comment.