error[E0445]: private trait `Private<::P, ::R>` in public interface --> $DIR/issue-18389.rs:14:1 | LL | trait Private { | ------------------- `Private<::P, ::R>` declared as private ... LL | / pub trait Public: Private< LL | | LL | | LL | | ::P, LL | | ::R LL | | > { | |_^ can't leak private trait warning: trait `Private<::P, ::R>` is more private than the item `Public` --> $DIR/issue-18389.rs:14:1 | LL | / pub trait Public: Private< LL | | LL | | LL | | ::P, LL | | ::R LL | | > { | |_^ trait `Public` is reachable at visibility `pub` | note: but trait `Private<::P, ::R>` is only usable at visibility `pub(crate)` --> $DIR/issue-18389.rs:11:1 | LL | trait Private { | ^^^^^^^^^^^^^^^^^^^ note: the lint level is defined here --> $DIR/issue-18389.rs:2:9 | LL | #![warn(private_bounds)] | ^^^^^^^^^^^^^^ error: aborting due to previous error; 1 warning emitted For more information about this error, try `rustc --explain E0445`.