Fix/Ignore doc tests

This commit is contained in:
flip1995 2019-03-10 23:01:56 +01:00
parent 44c46d2059
commit 72aeaa891b
No known key found for this signature in database
GPG key ID: 04461221D4DFB954
6 changed files with 13 additions and 10 deletions

View file

@ -16,7 +16,7 @@ declare_clippy_lint! {
/// **Known problems:** None /// **Known problems:** None
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust,ignore
/// assert!(false) /// assert!(false)
/// // or /// // or
/// assert!(true) /// assert!(true)

View file

@ -22,7 +22,8 @@ declare_clippy_lint! {
/// **Example:** /// **Example:**
/// ```rust /// ```rust
/// let mut a = 5; /// let mut a = 5;
/// ... /// let b = 0;
/// // ...
/// a = a + b; /// a = a + b;
/// ``` /// ```
pub ASSIGN_OP_PATTERN, pub ASSIGN_OP_PATTERN,

View file

@ -17,9 +17,10 @@ declare_clippy_lint! {
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust
/// let x = 1;
/// 0 / x; /// 0 / x;
/// 0 * x; /// 0 * x;
/// x & 0 /// x & 0;
/// ``` /// ```
pub ERASING_OP, pub ERASING_OP,
correctness, correctness,

View file

@ -23,7 +23,7 @@ declare_clippy_lint! {
/// See rust-lang/rust-clippy#1439 for more details. /// See rust-lang/rust-clippy#1439 for more details.
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust,ignore
/// xs.map(|x| foo(x)) /// xs.map(|x| foo(x))
/// ``` /// ```
/// where `foo(_)` is a plain function that takes the exact argument type of /// where `foo(_)` is a plain function that takes the exact argument type of

View file

@ -37,7 +37,7 @@ declare_clippy_lint! {
/// **Example:** /// **Example:**
/// ```rust /// ```rust
/// fn foo(ref x: u8) -> bool { /// fn foo(ref x: u8) -> bool {
/// .. /// true
/// } /// }
/// ``` /// ```
pub TOPLEVEL_REF_ARG, pub TOPLEVEL_REF_ARG,

View file

@ -40,7 +40,7 @@ declare_clippy_lint! {
/// **Known problems:** None. /// **Known problems:** None.
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust,ignore
/// struct X { /// struct X {
/// values: Box<Vec<Foo>>, /// values: Box<Vec<Foo>>,
/// } /// }
@ -48,7 +48,7 @@ declare_clippy_lint! {
/// ///
/// Better: /// Better:
/// ///
/// ```rust /// ```rust,ignore
/// struct X { /// struct X {
/// values: Vec<Foo>, /// values: Vec<Foo>,
/// } /// }
@ -101,6 +101,7 @@ declare_clippy_lint! {
/// fn x() -> Option<Option<u32>> { /// fn x() -> Option<Option<u32>> {
/// None /// None
/// } /// }
/// ```
pub OPTION_OPTION, pub OPTION_OPTION,
complexity, complexity,
"usage of `Option<Option<T>>`" "usage of `Option<Option<T>>`"
@ -150,13 +151,13 @@ declare_clippy_lint! {
/// **Known problems:** None. /// **Known problems:** None.
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust,ignore
/// fn foo(bar: &Box<T>) { ... } /// fn foo(bar: &Box<T>) { ... }
/// ``` /// ```
/// ///
/// Better: /// Better:
/// ///
/// ```rust /// ```rust,ignore
/// fn foo(bar: &T) { ... } /// fn foo(bar: &T) { ... }
/// ``` /// ```
pub BORROWED_BOX, pub BORROWED_BOX,
@ -1537,7 +1538,7 @@ declare_clippy_lint! {
/// like `#[cfg(target_pointer_width = "64")] ..` instead. /// like `#[cfg(target_pointer_width = "64")] ..` instead.
/// ///
/// **Example:** /// **Example:**
/// ```rust /// ```rust,ignore
/// vec.len() <= 0 /// vec.len() <= 0
/// 100 > std::i32::MAX /// 100 > std::i32::MAX
/// ``` /// ```