1 // gate-test-dropck_eyepatch
2 
3 // Check that `may_dangle` is rejected if `dropck_eyepatch` feature gate is absent.
4 
5 struct Pt<A>(A);
6 unsafe impl<#[may_dangle] A> Drop for Pt<A> {
7     //~^ ERROR `may_dangle` has unstable semantics and may be removed in the future
drop(&mut self)8     fn drop(&mut self) { }
9 }
10 
main()11 fn main() {}
12