1 // rustfmt-wrap_comments: true
2 // rustfmt-normalize_doc_attributes: true
4 // Only doc = "" attributes should be normalized
5 #![doc = " Example doc attribute comment"]
6 #![doc = " Example doc attribute comment with 10 leading spaces"]
7 #![doc(html_logo_url = "https://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
8 html_favicon_url = "https://doc.rust-lang.org/favicon.ico",
9 html_root_url = "https://doc.rust-lang.org/nightly/",
10 html_playground_url = "https://play.rust-lang.org/", test(attr(deny(warnings))))]
13 // Long `#[doc = "..."]`
14 struct A { #[doc = " xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"] b: i32 }
17 #[doc = " The `nodes` and `edges` method each return instantiations of `Cow<[T]>` to leave implementers the freedom to create entirely new vectors or to pass back slices into internally owned vectors."]
21 #[doc = " Level 1 comment"]
23 #[doc = " Level 2 comment"]
25 #[doc = " Level 3 comment"]
27 #[doc = " Level 4 comment"]
35 #[doc = " item doc attrib comment"]
36 // regular item comment
39 // regular item comment
40 #[doc = " item doc attrib comment"]
44 // non-regression test for regular attributes, from #2647
45 #[cfg(feature = "this_line_is_101_characters_long_xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx")]
50 #[clippy::bar(a, b, c)]
54 #[derive(Debug, StructOpt)]
55 #[structopt(about = "Display information about the character on FF Logs")]
57 #[structopt(help = "The server the character is on")]
59 #[structopt(help = "The character's first name")]
61 #[structopt(help = "The character's last name")]
66 help = "The job to look at",
73 // non-regression test for regular attributes, from #2969
74 #[cfg(not(all(feature="std",
75 any(target_os = "linux", target_os = "android",
77 target_os = "dragonfly",
79 target_os = "emscripten",
80 target_os = "solaris",
81 target_os = "cloudabi",
82 target_os = "macos", target_os = "ios",
83 target_os = "freebsd",
84 target_os = "openbsd",
86 target_os = "fuchsia",
88 all(target_arch = "wasm32", feature = "stdweb"),
89 all(target_arch = "wasm32", feature = "wasm-bindgen"),
93 // use cases from bindgen needing precise control over leading spaces
94 #[doc = " <div rustbindgen accessor></div>"]
96 #[derive(Debug, Default, Copy, Clone)]
97 pub struct ContradictAccessors {
98 #[doc = "<foo>no leading spaces here</foo>"]
99 pub mBothAccessors: ::std::os::raw::c_int,
100 #[doc = " <div rustbindgen accessor=\"false\"></div>"]
101 pub mNoAccessors: ::std::os::raw::c_int,
102 #[doc = " <div rustbindgen accessor=\"unsafe\"></div>"]
103 pub mUnsafeAccessors: ::std::os::raw::c_int,
104 #[doc = " <div rustbindgen accessor=\"immutable\"></div>"]
105 pub mImmutableAccessor: ::std::os::raw::c_int,
108 #[doc = " \\brief MPI structure"]
110 #[derive(Debug, Copy, Clone)]
111 pub struct mbedtls_mpi {
112 #[doc = "< integer sign"]
113 pub s: ::std::os::raw::c_int,
114 #[doc = "< total # of limbs"]
115 pub n: ::std::os::raw::c_ulong,
116 #[doc = "< pointer to limbs"]
117 pub p: *mut mbedtls_mpi_uint,