diff options
| author | varkor <github@varkor.com> | 2018-11-03 21:09:53 +0000 |
|---|---|---|
| committer | varkor <github@varkor.com> | 2018-11-03 23:53:10 +0000 |
| commit | 8277ba2d30996067c39ee3405bd141b11ffdb855 (patch) | |
| tree | d9da2d3adf56b5896ddb5f63ef1981b68a73e0e7 /src | |
| parent | 3d28ee3e34d100534062d0bc690779ed9b6927fe (diff) | |
| download | rust-8277ba2d30996067c39ee3405bd141b11ffdb855.tar.gz rust-8277ba2d30996067c39ee3405bd141b11ffdb855.zip | |
Make "all possible cases" help message uniform with existing help messages
Specifically no capitalisation or trailing full stops.
Diffstat (limited to 'src')
| -rw-r--r-- | src/librustc_mir/hair/pattern/check_match.rs | 4 | ||||
| -rw-r--r-- | src/test/ui/error-codes/E0004-2.stderr | 2 | ||||
| -rw-r--r-- | src/test/ui/issues/issue-3096-1.stderr | 2 | ||||
| -rw-r--r-- | src/test/ui/issues/issue-3096-2.stderr | 2 | ||||
| -rw-r--r-- | src/test/ui/uninhabited/uninhabited-matches-feature-gated.stderr | 6 |
5 files changed, 8 insertions, 8 deletions
diff --git a/src/librustc_mir/hair/pattern/check_match.rs b/src/librustc_mir/hair/pattern/check_match.rs index f2ae5774da8..735ceef229a 100644 --- a/src/librustc_mir/hair/pattern/check_match.rs +++ b/src/librustc_mir/hair/pattern/check_match.rs @@ -238,8 +238,8 @@ impl<'a, 'tcx> MatchVisitor<'a, 'tcx> { is non-empty", pat_ty)); span_help!(&mut err, scrut.span, - "Please ensure that all possible cases are being handled; \ - possibly adding wildcards or more match arms."); + "ensure that all possible cases are being handled, \ + possibly by adding wildcards or more match arms"); err.emit(); } // If the type *is* uninhabited, it's vacuously exhaustive diff --git a/src/test/ui/error-codes/E0004-2.stderr b/src/test/ui/error-codes/E0004-2.stderr index 6a4392df35d..900812787bc 100644 --- a/src/test/ui/error-codes/E0004-2.stderr +++ b/src/test/ui/error-codes/E0004-2.stderr @@ -4,7 +4,7 @@ error[E0004]: non-exhaustive patterns: type std::option::Option<i32> is non-empt LL | match x { } //~ ERROR E0004 | ^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/E0004-2.rs:14:11 | LL | match x { } //~ ERROR E0004 diff --git a/src/test/ui/issues/issue-3096-1.stderr b/src/test/ui/issues/issue-3096-1.stderr index 783e831a2a5..b2bfe6b5e8c 100644 --- a/src/test/ui/issues/issue-3096-1.stderr +++ b/src/test/ui/issues/issue-3096-1.stderr @@ -4,7 +4,7 @@ error[E0004]: non-exhaustive patterns: type () is non-empty LL | match () { } //~ ERROR non-exhaustive | ^^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/issue-3096-1.rs:12:11 | LL | match () { } //~ ERROR non-exhaustive diff --git a/src/test/ui/issues/issue-3096-2.stderr b/src/test/ui/issues/issue-3096-2.stderr index 6031f25c03d..bb9dfabe7be 100644 --- a/src/test/ui/issues/issue-3096-2.stderr +++ b/src/test/ui/issues/issue-3096-2.stderr @@ -4,7 +4,7 @@ error[E0004]: non-exhaustive patterns: type *const bottom is non-empty LL | match x { } //~ ERROR non-exhaustive patterns | ^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/issue-3096-2.rs:15:11 | LL | match x { } //~ ERROR non-exhaustive patterns diff --git a/src/test/ui/uninhabited/uninhabited-matches-feature-gated.stderr b/src/test/ui/uninhabited/uninhabited-matches-feature-gated.stderr index d86ebda027e..83fd736a997 100644 --- a/src/test/ui/uninhabited/uninhabited-matches-feature-gated.stderr +++ b/src/test/ui/uninhabited/uninhabited-matches-feature-gated.stderr @@ -10,7 +10,7 @@ error[E0004]: non-exhaustive patterns: type &Void is non-empty LL | let _ = match x {}; //~ ERROR non-exhaustive | ^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/uninhabited-matches-feature-gated.rs:20:19 | LL | let _ = match x {}; //~ ERROR non-exhaustive @@ -22,7 +22,7 @@ error[E0004]: non-exhaustive patterns: type (Void,) is non-empty LL | let _ = match x {}; //~ ERROR non-exhaustive | ^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/uninhabited-matches-feature-gated.rs:23:19 | LL | let _ = match x {}; //~ ERROR non-exhaustive @@ -34,7 +34,7 @@ error[E0004]: non-exhaustive patterns: type [Void; 1] is non-empty LL | let _ = match x {}; //~ ERROR non-exhaustive | ^ | -help: Please ensure that all possible cases are being handled; possibly adding wildcards or more match arms. +help: ensure that all possible cases are being handled, possibly by adding wildcards or more match arms --> $DIR/uninhabited-matches-feature-gated.rs:26:19 | LL | let _ = match x {}; //~ ERROR non-exhaustive |
