Is it? I honestly haven't noticed. Do we have a style guide for this sort
of thing?


On Sun, Nov 24, 2013 at 9:30 PM, Huon Wilson <notifications@github.com>wrote:

> In src/libsyntax/parse/parser.rs:
>
> > @@ -2086,15 +2086,13 @@ impl Parser {
> >          fn parse_non_delim_tt_tok(p: &Parser) -> token_tree {
> >              maybe_whole!(deref p, nt_tt);
> >              match *p.token {
> > -              token::RPAREN | token::RBRACE | token::RBRACKET
> > -              => {
> > -                p.fatal(
> > -                    format!(
> > -                        "incorrect close delimiter: `{}`",
> > -                        p.this_token_to_str()
> > -                    )
> > -                );
> > -              }
> > +              token::RPAREN | token::RBRACE | token::RBRACKET => {
> > +                  // This is a conservative error: only report the last unclosed delimiter. The
> > +                  // previous unclosed delimiters could actually be closed! The parser just hasn't
> > +                  // gotten to them yet.
> > +                  p.open_braces.iter().last().map(|sp| p.span_note(*sp, "Unclosed delimiter"));
> > +                  p.fatal(format!("Incorrect close delimiter: `{}`", p.this_token_to_str()));
>
> Isn't the conventional error formatting with a lower-case leading letter?
>
> —
> Reply to this email directly or view it on GitHub<https://github.com/mozilla/rust/pull/10641/files#r7881939>
> .
>