Minor documentation cleanups
This commit is contained in:
@@ -16,9 +16,9 @@ pub struct EscapePass;
|
|||||||
|
|
||||||
/// **What it does:** This lint checks for usage of `Box<T>` where an unboxed `T` would work fine. It is `Warn` by default.
|
/// **What it does:** This lint checks for usage of `Box<T>` where an unboxed `T` would work fine. It is `Warn` by default.
|
||||||
///
|
///
|
||||||
/// **Why is this bad?** This is an unnecessary allocation, and bad for performance
|
/// **Why is this bad?** This is an unnecessary allocation, and bad for performance. It is only necessary to allocate if you wish to move the box into something.
|
||||||
///
|
///
|
||||||
/// It is only necessary to allocate if you wish to move the box into something.
|
/// **Known problems:** None
|
||||||
///
|
///
|
||||||
/// **Example:**
|
/// **Example:**
|
||||||
///
|
///
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ use syntax::ast::*;
|
|||||||
|
|
||||||
use utils::{span_lint, snippet};
|
use utils::{span_lint, snippet};
|
||||||
|
|
||||||
/// **What it does:** This lint checks for operations where precedence may be unclear and `Warn`'s about them by default, suggesting to add parentheses. Currently it catches the following:
|
/// **What it does:** This lint checks for operations where precedence may be unclear and `Warn`s about them by default, suggesting to add parentheses. Currently it catches the following:
|
||||||
/// * mixed usage of arithmetic and bit shifting/combining operators without parentheses
|
/// * mixed usage of arithmetic and bit shifting/combining operators without parentheses
|
||||||
/// * a "negative" numeric literal (which is really a unary `-` followed by a numeric literal) followed by a method call
|
/// * a "negative" numeric literal (which is really a unary `-` followed by a numeric literal) followed by a method call
|
||||||
///
|
///
|
||||||
|
|||||||
Reference in New Issue
Block a user