diff options
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/feature_gate.rs | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs index 2802ad3c3e3..4dc4e69aa55 100644 --- a/src/libsyntax/feature_gate.rs +++ b/src/libsyntax/feature_gate.rs @@ -305,6 +305,26 @@ impl<'a, 'v> Visitor<'v> for PostExpansionVisitor<'a> { many unsafe patterns and may be \ removed in the future"); } + + if attr::contains_name(i.attrs[], + "old_orphan_check") { + self.gate_feature( + "old_orphan_check", + i.span, + "the new orphan check rules will eventually be strictly enforced"); + } + + for item in items.iter() { + match *item { + ast::MethodImplItem(_) => {} + ast::TypeImplItem(ref typedef) => { + self.gate_feature("associated_types", + typedef.span, + "associated types are \ + experimental") + } + } + } } _ => {} |
