diff options
Diffstat (limited to 'src/lib.rs')
-rw-r--r-- | src/lib.rs | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -236,6 +236,7 @@ mod tests { parse_derive(ast); } + #[doc = "Matches dar\n\nMatch dar description\n"] #[test] fn test_generate_doc() { let input = quote! { @@ -247,17 +248,17 @@ mod tests { let token = super::derive_parser(input, true); let expected = quote! { - #[doc = "A parser for JSON file.\nAnd this is a example for JSON parser.\n\n indent-4-space"] + #[doc = "A parser for JSON file.\nAnd this is a example for JSON parser.\n\n indent-4-space\n"] #[allow(dead_code, non_camel_case_types, clippy::upper_case_acronyms)] #[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)] pub enum Rule { #[doc = "Matches foo str, e.g.: `foo`"] r#foo, - #[doc = "Matches bar str,\n Indent 2, e.g: `bar` or `foobar`"] + #[doc = "Matches bar str\n\n Indent 2, e.g: `bar` or `foobar`"] r#bar, r#bar1, - #[doc = "Matches dar\nMatch dar description"] + #[doc = "Matches dar\n\nMatch dar description\n"] r#dar } }; |