]> git.lizzy.rs Git - rust.git/blobdiff - tests/ui/doc.rs
iterate List by value
[rust.git] / tests / ui / doc.rs
index 4a34b561d03f8bf6c6ee70167f9c7cbc0c0e8f9e..77620c857e66e2ca52e5f40fc0887eba94f0fd1e 100644 (file)
@@ -1,12 +1,12 @@
-//! This file tests for the DOC_MARKDOWN lint
+//! This file tests for the `DOC_MARKDOWN` lint.
 
-#![feature(plugin)]
-#![plugin(clippy)]
 #![allow(dead_code)]
-#![warn(doc_markdown)]
+#![warn(clippy::doc_markdown)]
+#![feature(custom_inner_attributes)]
+#![rustfmt::skip]
 
 /// The foo_bar function does _nothing_. See also foo::bar. (note the dot there)
-/// Markdown is _weird_. I mean _really weird_.  This \_ is ok. So is `_`. But not Foo::some_fun
+/// Markdown is _weird_. I mean _really weird_. This \_ is ok. So is `_`. But not Foo::some_fun
 /// which should be reported only once despite being __doubly bad__.
 /// Here be ::a::global:path.
 /// That's not code ~NotInCodeBlock~.
@@ -50,7 +50,7 @@ fn test_units() {
 }
 
 /// This test has [a link_with_underscores][chunked-example] inside it. See #823.
-/// See also [the issue tracker](https://github.com/rust-lang-nursery/rust-clippy/search?q=doc_markdown&type=Issues)
+/// See also [the issue tracker](https://github.com/rust-lang/rust-clippy/search?q=clippy::doc_markdown&type=Issues)
 /// on GitHub (which is a camel-cased word, but is OK). And here is another [inline link][inline_link].
 /// It can also be [inline_link2].
 ///
@@ -71,7 +71,7 @@ fn main() {
 }
 
 /// ## CamelCaseThing
-/// Talks about `CamelCaseThing`. Titles should be ignored, see issue #897.
+/// Talks about `CamelCaseThing`. Titles should be ignored; see issue #897.
 ///
 /// # CamelCaseThing
 ///
@@ -107,7 +107,7 @@ fn issue883() {
 fn multiline() {
 }
 
-/** E.g. serialization of an empty list: FooBar
+/** E.g., serialization of an empty list: FooBar
 ```
 That's in a code block: `PackedNode`
 ```
@@ -118,7 +118,7 @@ fn multiline() {
 fn issue1073() {
 }
 
-/** E.g. serialization of an empty list: FooBar
+/** E.g., serialization of an empty list: FooBar
 ```
 That's in a code block: PackedNode
 ```
@@ -129,7 +129,7 @@ fn issue1073() {
 fn issue1073_alt() {
 }
 
-/// Test more than three quotes:
+/// Tests more than three quotes:
 /// ````
 /// DoNotWarn
 /// ```
@@ -142,7 +142,7 @@ fn four_quotes() {
 /// See [NIST SP 800-56A, revision 2].
 ///
 /// [NIST SP 800-56A, revision 2]:
-///     https://github.com/rust-lang-nursery/rust-clippy/issues/902#issuecomment-261919419
+///     https://github.com/rust-lang/rust-clippy/issues/902#issuecomment-261919419
 fn issue_902_comment() {}
 
 #[cfg_attr(feature = "a", doc = " ```")]
@@ -153,3 +153,32 @@ fn issue_902_comment() {}
 /// }
 /// ```
 fn issue_1469() {}
+
+/**
+ * This is a doc comment that should not be a list
+ *This would also be an error under a strict common mark interpretation
+ */
+fn issue_1920() {}
+
+/// Ok: <http://www.unicode.org/reports/tr9/#Reordering_Resolved_Levels>
+///
+/// Not ok: http://www.unicode.org
+/// Not ok: https://www.unicode.org
+/// Not ok: http://www.unicode.org/
+/// Not ok: http://www.unicode.org/reports/tr9/#Reordering_Resolved_Levels
+fn issue_1832() {}
+
+/// Ok: CamelCase (It should not be surrounded by backticks)
+fn issue_2395() {}
+
+/// An iterator over mycrate::Collection's values.
+/// It should not lint a `'static` lifetime in ticks.
+fn issue_2210() {}
+
+/// This should not cause the lint to trigger:
+/// #REQ-data-family.lint_partof_exists
+fn issue_2343() {}
+
+/// This should not cause an ICE:
+/// __|_ _|__||_|
+fn pulldown_cmark_crash() {}