2016-03-08 15:23:52 -08:00
|
|
|
// Check that specialization must be ungated to use the `default` keyword
|
|
|
|
|
2017-01-11 02:25:44 +01:00
|
|
|
// gate-test-specialization
|
|
|
|
|
2015-12-30 15:25:31 -08:00
|
|
|
trait Foo {
|
|
|
|
fn foo(&self);
|
|
|
|
}
|
|
|
|
|
|
|
|
impl<T> Foo for T {
|
2016-03-08 15:23:52 -08:00
|
|
|
default fn foo(&self) {} //~ ERROR specialization is unstable
|
2015-12-30 15:25:31 -08:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|