From 48f50e1e98691d74427e23e82694f528b3fb4d56 Mon Sep 17 00:00:00 2001 From: Nick Cameron Date: Tue, 6 Jan 2015 09:44:33 +1300 Subject: Obsolete `Sized? T` [breaking-change] Use `T: ?Sized` --- src/libsyntax/parse/parser.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/libsyntax/parse/parser.rs') diff --git a/src/libsyntax/parse/parser.rs b/src/libsyntax/parse/parser.rs index cf7b93ac59f..673a9aefd8b 100644 --- a/src/libsyntax/parse/parser.rs +++ b/src/libsyntax/parse/parser.rs @@ -4092,8 +4092,8 @@ impl<'a> Parser<'a> { // unbound, and it may only be `Sized`. To avoid backtracking and other // complications, we parse an ident, then check for `?`. If we find it, // we use the ident as the unbound, otherwise, we use it as the name of - // type param. Even worse, for now, we need to check for `?` before or - // after the bound. + // type param. Even worse, we need to check for `?` before or after the + // bound. let mut span = self.span; let mut ident = self.parse_ident(); let mut unbound = None; @@ -4102,6 +4102,7 @@ impl<'a> Parser<'a> { unbound = Some(tref); span = self.span; ident = self.parse_ident(); + self.obsolete(span, ObsoleteSyntax::Sized); } let mut bounds = self.parse_colon_then_ty_param_bounds(BoundParsingMode::Modified); -- cgit 1.4.1-3-g733a5