From 43492283b4952a0d6d55fbadfe53d48264f2f2b4 Mon Sep 17 00:00:00 2001 From: Yuki Okushi Date: Fri, 15 Nov 2019 03:05:03 +0900 Subject: [PATCH] Don't warn labels beginning with `_` --- src/librustc_resolve/late.rs | 4 +++- src/test/ui/label/label-beginning-with-underscore.rs | 10 ++++++++++ 2 files changed, 13 insertions(+), 1 deletion(-) create mode 100644 src/test/ui/label/label-beginning-with-underscore.rs diff --git a/src/librustc_resolve/late.rs b/src/librustc_resolve/late.rs index 24d6331bbd37d..6b0683879740a 100644 --- a/src/librustc_resolve/late.rs +++ b/src/librustc_resolve/late.rs @@ -1767,7 +1767,9 @@ impl<'a, 'b> LateResolutionVisitor<'a, '_> { fn with_resolved_label(&mut self, label: Option