about summary refs log tree commit diff
diff options
context:
space:
mode:
authorZack M. Davis <code@zackmdavis.net>2017-01-05 20:01:22 -0800
committerZack M. Davis <code@zackmdavis.net>2017-02-04 10:51:11 -0800
commit72af42e8974f521e3fed753feac3d0638ad61025 (patch)
tree68ab102a9ffddb4bd7a13c32e790e0770528b5d9
parent778958f25661a41081878ffbb1a589d926d5bd2a (diff)
downloadrust-72af42e8974f521e3fed753feac3d0638ad61025.tar.gz
rust-72af42e8974f521e3fed753feac3d0638ad61025.zip
note wording: lint implied by lint group, not lint group implies lint
-rw-r--r--src/librustc/lint/context.rs8
-rw-r--r--src/test/compile-fail/issue-30730.rs2
-rw-r--r--src/test/ui/lint/command-line-lint-group-deny.stderr2
-rw-r--r--src/test/ui/lint/command-line-lint-group-forbid.stderr2
-rw-r--r--src/test/ui/lint/command-line-lint-group-warn.stderr2
-rw-r--r--src/test/ui/lint/lint-group-style.stderr10
-rw-r--r--src/test/ui/span/issue-24690.stderr6
7 files changed, 16 insertions, 16 deletions
diff --git a/src/librustc/lint/context.rs b/src/librustc/lint/context.rs
index 28600e3ab8e..32bc81e9470 100644
--- a/src/librustc/lint/context.rs
+++ b/src/librustc/lint/context.rs
@@ -483,16 +483,16 @@ pub fn raw_struct_lint<'a, S>(sess: &'a Session,
                                   flag, hyphen_case_lint_name));
             } else {
                 let hyphen_case_flag_val = lint_flag_val.as_str().replace("_", "-");
-                err.note(&format!("`{} {}` implies `{} {}`",
-                                  flag, hyphen_case_flag_val, flag, hyphen_case_lint_name));
+                err.note(&format!("`{} {}` implied by `{} {}`",
+                                  flag, hyphen_case_lint_name, flag, hyphen_case_flag_val));
             }
         },
         Node(lint_attr_name, src) => {
             def = Some(src);
             if lint_attr_name.as_str().deref() != name {
                 let level_str = level.as_str();
-                err.note(&format!("#[{}({})] implies #[{}({})]",
-                                  level_str, lint_attr_name, level_str, name));
+                err.note(&format!("#[{}({})] implied by #[{}({})]",
+                                  level_str, name, level_str, lint_attr_name));
             }
         }
     }
diff --git a/src/test/compile-fail/issue-30730.rs b/src/test/compile-fail/issue-30730.rs
index 6082740f427..086938334c7 100644
--- a/src/test/compile-fail/issue-30730.rs
+++ b/src/test/compile-fail/issue-30730.rs
@@ -11,5 +11,5 @@
 #![deny(warnings)] //~ NOTE: lint level defined here
 use std::thread;
 //~^ ERROR: unused import
-//~| NOTE: #[deny(warnings)] implies #[deny(unused_imports)]
+//~| NOTE: #[deny(unused_imports)] implied by #[deny(warnings)]
 fn main() {}
diff --git a/src/test/ui/lint/command-line-lint-group-deny.stderr b/src/test/ui/lint/command-line-lint-group-deny.stderr
index eafbf944dea..23fac66cc6c 100644
--- a/src/test/ui/lint/command-line-lint-group-deny.stderr
+++ b/src/test/ui/lint/command-line-lint-group-deny.stderr
@@ -4,7 +4,7 @@ error: variable `_InappropriateCamelCasing` should have a snake case name such a
 14 |     let _InappropriateCamelCasing = true;
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: `-D bad-style` implies `-D non-snake-case`
+   = note: `-D non-snake-case` implied by `-D bad-style`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/lint/command-line-lint-group-forbid.stderr b/src/test/ui/lint/command-line-lint-group-forbid.stderr
index 0cf896060a2..0babd7f6fe4 100644
--- a/src/test/ui/lint/command-line-lint-group-forbid.stderr
+++ b/src/test/ui/lint/command-line-lint-group-forbid.stderr
@@ -4,7 +4,7 @@ error: variable `_InappropriateCamelCasing` should have a snake case name such a
 14 |     let _InappropriateCamelCasing = true;
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: `-F bad-style` implies `-F non-snake-case`
+   = note: `-F non-snake-case` implied by `-F bad-style`
 
 error: aborting due to previous error
 
diff --git a/src/test/ui/lint/command-line-lint-group-warn.stderr b/src/test/ui/lint/command-line-lint-group-warn.stderr
index 4ffbff6cdb7..998c892c7e3 100644
--- a/src/test/ui/lint/command-line-lint-group-warn.stderr
+++ b/src/test/ui/lint/command-line-lint-group-warn.stderr
@@ -4,5 +4,5 @@ warning: variable `_InappropriateCamelCasing` should have a snake case name such
 14 |     let _InappropriateCamelCasing = true;
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: `-W bad-style` implies `-W non-snake-case`
+   = note: `-W non-snake-case` implied by `-W bad-style`
 
diff --git a/src/test/ui/lint/lint-group-style.stderr b/src/test/ui/lint/lint-group-style.stderr
index 93f6399b227..9c0f4866af6 100644
--- a/src/test/ui/lint/lint-group-style.stderr
+++ b/src/test/ui/lint/lint-group-style.stderr
@@ -4,7 +4,7 @@ error: function `CamelCase` should have a snake case name such as `camel_case`
 14 | fn CamelCase() {}
    | ^^^^^^^^^^^^^^^^^
    |
-   = note: #[deny(bad_style)] implies #[deny(non_snake_case)]
+   = note: #[deny(non_snake_case)] implied by #[deny(bad_style)]
 note: lint level defined here
   --> $DIR/lint-group-style.rs:11:9
    |
@@ -17,7 +17,7 @@ error: function `CamelCase` should have a snake case name such as `camel_case`
 22 |         fn CamelCase() {}
    |         ^^^^^^^^^^^^^^^^^
    |
-   = note: #[forbid(bad_style)] implies #[forbid(non_snake_case)]
+   = note: #[forbid(non_snake_case)] implied by #[forbid(bad_style)]
 note: lint level defined here
   --> $DIR/lint-group-style.rs:20:14
    |
@@ -30,7 +30,7 @@ error: static variable `bad` should have an upper case name such as `BAD`
 24 |         static bad: isize = 1;
    |         ^^^^^^^^^^^^^^^^^^^^^^
    |
-   = note: #[forbid(bad_style)] implies #[forbid(non_upper_case_globals)]
+   = note: #[forbid(non_upper_case_globals)] implied by #[forbid(bad_style)]
 note: lint level defined here
   --> $DIR/lint-group-style.rs:20:14
    |
@@ -43,7 +43,7 @@ warning: function `CamelCase` should have a snake case name such as `camel_case`
 30 |         fn CamelCase() {}
    |         ^^^^^^^^^^^^^^^^^
    |
-   = note: #[warn(bad_style)] implies #[warn(non_snake_case)]
+   = note: #[warn(non_snake_case)] implied by #[warn(bad_style)]
 note: lint level defined here
   --> $DIR/lint-group-style.rs:28:17
    |
@@ -56,7 +56,7 @@ warning: type `snake_case` should have a camel case name such as `SnakeCase`
 32 |         struct snake_case;
    |         ^^^^^^^^^^^^^^^^^^
    |
-   = note: #[warn(bad_style)] implies #[warn(non_camel_case_types)]
+   = note: #[warn(non_camel_case_types)] implied by #[warn(bad_style)]
 note: lint level defined here
   --> $DIR/lint-group-style.rs:28:17
    |
diff --git a/src/test/ui/span/issue-24690.stderr b/src/test/ui/span/issue-24690.stderr
index 623bb4a0d26..c4f2616f594 100644
--- a/src/test/ui/span/issue-24690.stderr
+++ b/src/test/ui/span/issue-24690.stderr
@@ -4,7 +4,7 @@ error: variable `theTwo` should have a snake case name such as `the_two`
 19 |     let theTwo = 2;
    |         ^^^^^^
    |
-   = note: #[deny(warnings)] implies #[deny(non_snake_case)]
+   = note: #[deny(non_snake_case)] implied by #[deny(warnings)]
 note: lint level defined here
   --> $DIR/issue-24690.rs:16:9
    |
@@ -17,7 +17,7 @@ error: variable `theOtherTwo` should have a snake case name such as `the_other_t
 20 |     let theOtherTwo = 2;
    |         ^^^^^^^^^^^
    |
-   = note: #[deny(warnings)] implies #[deny(non_snake_case)]
+   = note: #[deny(non_snake_case)] implied by #[deny(warnings)]
 
 error: unused variable: `theOtherTwo`
   --> $DIR/issue-24690.rs:20:9
@@ -25,7 +25,7 @@ error: unused variable: `theOtherTwo`
 20 |     let theOtherTwo = 2;
    |         ^^^^^^^^^^^
    |
-   = note: #[deny(warnings)] implies #[deny(unused_variables)]
+   = note: #[deny(unused_variables)] implied by #[deny(warnings)]
 note: lint level defined here
   --> $DIR/issue-24690.rs:16:9
    |