diff options
| author | leonardo.yvens <leoyvens@gmail.com> | 2017-10-09 13:59:20 -0300 |
|---|---|---|
| committer | leonardo.yvens <leoyvens@gmail.com> | 2017-11-03 16:13:20 -0200 |
| commit | 06506bb751ae952b67d76a2ebe21edb8ec96acb9 (patch) | |
| tree | 9894a2984347c30c31cc59c933ce0b1a30007086 /src/libsyntax/parse | |
| parent | 5ce3d482e2313fe6795e6d688e62a092af424da8 (diff) | |
| download | rust-06506bb751ae952b67d76a2ebe21edb8ec96acb9.tar.gz rust-06506bb751ae952b67d76a2ebe21edb8ec96acb9.zip | |
[Syntax Breaking] Rename DefaultImpl to AutoImpl
DefaultImpl is a highly confusing name for what we now call auto impls, as in `impl Send for ..`. The name auto impl is not formally decided but for sanity anything is better than `DefaultImpl` which refers neither to `default impl` nor to `impl Default`.
Diffstat (limited to 'src/libsyntax/parse')
| -rw-r--r-- | src/libsyntax/parse/parser.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index a3a265450ab..fa6a3b669fa 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -5133,19 +5133,19 @@ impl<'a> Parser<'a> { if opt_trait.is_some() && self.eat(&token::DotDot) { if generics.is_parameterized() { - self.span_err(impl_span, "default trait implementations are not \ + self.span_err(impl_span, "auto trait implementations are not \ allowed to have generics"); } if let ast::Defaultness::Default = defaultness { self.span_err(impl_span, "`default impl` is not allowed for \ - default trait implementations"); + auto trait implementations"); } self.expect(&token::OpenDelim(token::Brace))?; self.expect(&token::CloseDelim(token::Brace))?; Ok((keywords::Invalid.ident(), - ItemKind::DefaultImpl(unsafety, opt_trait.unwrap()), None)) + ItemKind::AutoImpl(unsafety, opt_trait.unwrap()), None)) } else { if opt_trait.is_some() { ty = self.parse_ty()?; |
