Skip to content

Commit

Permalink
Reduce stderr size
Browse files Browse the repository at this point in the history
  • Loading branch information
pmk21 committed Apr 9, 2020
1 parent dd0fd99 commit aefab0e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 68 deletions.
25 changes: 0 additions & 25 deletions tests/ui/implicit_saturating_sub.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,31 +177,6 @@ fn main() {

let mut i_64: i64 = endi_64 - starti_64;

// Lint
if i_64 > i64::MIN {
i_64 -= 1;
}

// Lint
if i_64 > i64::min_value() {
i_64 -= 1;
}

// Lint
if i_64 != i64::MIN {
i_64 -= 1;
}

// Lint
if i_64 != i64::min_value() {
i_64 -= 1;
}

// Lint
if i64::min_value() != i_64 {
i_64 -= 1;
}

// Lint
if i64::min_value() < i_64 {
i_64 -= 1;
Expand Down
46 changes: 3 additions & 43 deletions tests/ui/implicit_saturating_sub.stderr
Original file line number Diff line number Diff line change
Expand Up @@ -163,66 +163,26 @@ LL | | }
error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:181:5
|
LL | / if i_64 > i64::MIN {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:186:5
|
LL | / if i_64 > i64::min_value() {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:191:5
|
LL | / if i_64 != i64::MIN {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:196:5
|
LL | / if i_64 != i64::min_value() {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:201:5
|
LL | / if i64::min_value() != i_64 {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:206:5
|
LL | / if i64::min_value() < i_64 {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:211:5
--> $DIR/implicit_saturating_sub.rs:186:5
|
LL | / if i64::MIN != i_64 {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: Implicitly performing saturating subtraction
--> $DIR/implicit_saturating_sub.rs:216:5
--> $DIR/implicit_saturating_sub.rs:191:5
|
LL | / if i64::MIN < i_64 {
LL | | i_64 -= 1;
LL | | }
| |_____^ help: try: `i_64 = i_64.saturating_sub(1);`

error: aborting due to 28 previous errors
error: aborting due to 23 previous errors

0 comments on commit aefab0e

Please sign in to comment.