Skip to content

Commit d7b3f58

Browse files
committed
---
yaml --- r: 1566 b: refs/heads/master c: 3c200f3 h: refs/heads/master v: v3
1 parent 08f119d commit d7b3f58

File tree

2 files changed

+6
-5
lines changed

2 files changed

+6
-5
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: 0a22a4edbb2300e338ef01c524265ecc647cbff4
2+
refs/heads/master: 3c200f3e14ff618431ea12c52031da43ee651984

trunk/src/comp/middle/typeck.rs

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1467,8 +1467,9 @@ fn check_pat(&@fn_ctxt fcx, @ast.pat pat) -> @ast.pat {
14671467
// TODO: pluralize properly
14681468
auto err_msg = "tag type " + last_id + " has " +
14691469
_uint.to_str(subpats_len, 10u) +
1470-
" fields, but this pattern has " +
1471-
_uint.to_str(arg_len, 10u) + " fields";
1470+
" field(s), but this pattern has " +
1471+
_uint.to_str(arg_len, 10u) +
1472+
" field(s)";
14721473

14731474
fcx.ccx.sess.span_err(pat.span, err_msg);
14741475
fail; // TODO: recover
@@ -1491,10 +1492,10 @@ fn check_pat(&@fn_ctxt fcx, @ast.pat pat) -> @ast.pat {
14911492
if (subpats_len > 0u) {
14921493
// TODO: pluralize properly
14931494
auto err_msg = "tag type " + last_id +
1494-
" has no fields," +
1495+
" has no field(s)," +
14951496
" but this pattern has " +
14961497
_uint.to_str(subpats_len, 10u) +
1497-
" fields";
1498+
" field(s)";
14981499

14991500
fcx.ccx.sess.span_err(pat.span, err_msg);
15001501
fail; // TODO: recover

0 commit comments

Comments
 (0)