Make private_in_public compatibility lint warn-by-default again

This commit is contained in:
Vadim Petrochenkov 2016-08-26 19:23:42 +03:00
parent 987b47549e
commit 3be6d1f954
6 changed files with 11 additions and 3 deletions

View file

@ -114,7 +114,7 @@ declare_lint! {
declare_lint! {
pub PRIVATE_IN_PUBLIC,
Deny,
Warn,
"detect private items in public interfaces not caught by the old implementation"
}

View file

@ -17,6 +17,8 @@ A private trait was used on a public type parameter bound. Erroneous code
examples:
```compile_fail,E0445
#![deny(private_in_public)]
trait Foo {
fn dummy(&self) { }
}
@ -45,6 +47,8 @@ E0446: r##"
A private type was used in a public type signature. Erroneous code example:
```compile_fail,E0446
#![deny(private_in_public)]
mod Foo {
struct Bar(u32);

View file

@ -8,6 +8,8 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![deny(private_in_public)]
pub use inner::C;
mod inner {

View file

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![deny(private_in_public)]
#![allow(unused)]
struct SemiPriv;

View file

@ -13,8 +13,8 @@
#![feature(associated_consts)]
#![feature(associated_type_defaults)]
#![allow(dead_code)]
#![allow(unused_variables)]
#![deny(private_in_public)]
#![allow(unused)]
#![allow(improper_ctypes)]
mod types {

View file

@ -8,6 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
#![deny(private_in_public)]
#![allow(dead_code)]
extern crate core;