]> git.lizzy.rs Git - rust.git/commitdiff
Rollup merge of #23782 - mvdnes:obsolete_note, r=alexcrichton
authorManish Goregaokar <manishsmail@gmail.com>
Fri, 17 Apr 2015 12:44:50 +0000 (18:14 +0530)
committerManish Goregaokar <manishsmail@gmail.com>
Fri, 17 Apr 2015 13:31:28 +0000 (19:01 +0530)
 When emmitting a note, previously it was not known if the note was for an error or a
warning. If it was for a warning, then with `-Awarnings` it should not have been print.
The `emit_for` function allows someone to specify which level should determine its visibility.

An example:
```rust
extern crate \"std\" as std2;
fn main() {}
```

When compiling with `-Awarnings`, this would previously emit `note: use an identifier not in quotes instead` (and nothing else).
With this patch, it will be completely silent as expected.


Trivial merge