about summary refs log tree commit diff
path: root/src/libsyntax
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2019-02-06 02:24:07 -0800
committerEsteban Küber <esteban@kuber.com.ar>2019-02-07 01:42:54 -0800
commit6e62129b363a1c10b08e0012ca5978d13f9c18e4 (patch)
tree7425af877652d13e0143568daccfdaecdc7ecc3e /src/libsyntax
parent336c48cc7b76865ca0d8608c89831d2669a8e368 (diff)
downloadrust-6e62129b363a1c10b08e0012ca5978d13f9c18e4.tar.gz
rust-6e62129b363a1c10b08e0012ca5978d13f9c18e4.zip
add doc comment and revert angle bracket change
Diffstat (limited to 'src/libsyntax')
-rw-r--r--src/libsyntax/parse/parser.rs8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs
index c0e5d6f1397..6dd4bfbb8d5 100644
--- a/src/libsyntax/parse/parser.rs
+++ b/src/libsyntax/parse/parser.rs
@@ -252,6 +252,9 @@ pub struct Parser<'a> {
     /// See the comments in the `parse_path_segment` function for more details.
     crate unmatched_angle_bracket_count: u32,
     crate max_angle_bracket_count: u32,
+    /// List of all unclosed delimiters found by the lexer. If an entry is used for error recovery
+    /// it gets removed from here. Every entry left at the end gets emitted as an independent
+    /// error.
     crate unclosed_delims: Vec<UnmatchedBrace>,
 }
 
@@ -5830,12 +5833,11 @@ impl<'a> Parser<'a> {
                     .span_suggestion(
                         span,
                         &format!(
-                            "{}remove extra angle bracket{}",
-                            if plural { "" } else { "maybe " }, // account for `S::<u64(3)`
+                            "remove extra angle bracket{}",
                             if plural { "s" } else { "" }
                         ),
                         String::new(),
-                        Applicability::MaybeIncorrect,
+                        Applicability::MachineApplicable,
                     )
                     .emit();