#![feature(simd, unsafe_destructor, slicing_syntax)]
#![feature(unboxed_closures)]
#![allow(unknown_features)] #![feature(int_uint)]
+#![feature(on_unimplemented)]
#![deny(missing_docs)]
#[macro_use]
let custom_note = report_on_unimplemented(infcx, &*trait_ref.0,
obligation.cause.span);
if let Some(s) = custom_note {
- infcx.tcx.sess.span_note(
- obligation.cause.span,
- s.as_slice());
+ infcx.tcx.sess.span_note(obligation.cause.span,
+ s.as_slice());
}
}
}
("visible_private_types", Active),
("slicing_syntax", Active),
("box_syntax", Active),
+ ("on_unimplemented", Active),
("if_let", Accepted),
("while_let", Accepted),
self.gate_feature("linkage", i.span,
"the `linkage` attribute is experimental \
and not portable across platforms")
+ } else if attr.name() == "rustc_on_unimplemented" {
+ self.gate_feature("on_unimplemented", i.span,
+ "the `#[rustc_on_unimplemented]` attribute \
+ is an experimental feature")
}
}
match i.node {
// except according to those terms.
// ignore-tidy-linelength
-#[allow(unused)]
+#![feature(on_unimplemented)]
+
+#![allow(unused)]
#[rustc_on_unimplemented = "test error `{Self}` with `{Bar}` `{Baz}` `{Quux}`"]
trait Foo<Bar, Baz, Quux>{}
// except according to those terms.
// ignore-tidy-linelength
+#![feature(on_unimplemented)]
+
#[rustc_on_unimplemented = "test error `{Self}` with `{Bar}` `{Baz}` `{Quux}`"]
trait Foo<Bar, Baz, Quux>{}