#![feature(negative_bounds, negative_impls)] //~^ WARN the feature `negative_bounds` is incomplete and may not be safe to use and/or cause compiler crashes fn not_copy() {} fn neg_param_env() { not_copy::(); } fn pos_param_env() { not_copy::(); //~^ ERROR the trait bound `T: !Copy` is not satisfied } fn unknown() { not_copy::(); //~^ ERROR the trait bound `T: !Copy` is not satisfied } struct NotCopyable; impl !Copy for NotCopyable {} fn neg_impl() { not_copy::(); } #[derive(Copy, Clone)] struct Copyable; fn pos_impl() { not_copy::(); //~^ ERROR the trait bound `Copyable: !Copy` is not satisfied } struct NotNecessarilyCopyable; fn unknown_impl() { not_copy::(); //~^ ERROR the trait bound `NotNecessarilyCopyable: !Copy` is not satisfied } fn main() {}