@@ -75,7 +75,6 @@ pub enum lint {
7575 non_camel_case_types,
7676 type_limits,
7777 default_methods,
78- deprecated_self,
7978 deprecated_mutable_fields,
8079 deprecated_drop,
8180 foreign_mode,
@@ -246,13 +245,6 @@ pub fn get_lint_dict() -> LintDict {
246245 default : deny
247246 } ) ,
248247
249- ( @~"deprecated_self",
250- @LintSpec {
251- lint : deprecated_self,
252- desc : "warn about deprecated uses of `self`" ,
253- default : warn
254- } ) ,
255-
256248 ( @~"deprecated_mutable_fields",
257249 @LintSpec {
258250 lint : deprecated_mutable_fields,
@@ -497,7 +489,6 @@ fn check_item(i: @ast::item, cx: ty::ctxt) {
497489 check_item_deprecated_modes ( cx, i) ;
498490 check_item_type_limits ( cx, i) ;
499491 check_item_default_methods ( cx, i) ;
500- check_item_deprecated_self ( cx, i) ;
501492 check_item_deprecated_mutable_fields ( cx, i) ;
502493 check_item_deprecated_drop ( cx, i) ;
503494}
@@ -677,46 +668,6 @@ fn check_item_default_methods(cx: ty::ctxt, item: @ast::item) {
677668 }
678669}
679670
680- fn check_item_deprecated_self ( cx : ty:: ctxt , item : @ast:: item ) {
681- fn maybe_warn ( cx : ty:: ctxt ,
682- item : @ast:: item ,
683- self_ty : ast:: self_ty ) {
684- match self_ty. node {
685- ast:: sty_by_ref => {
686- cx. sess . span_lint (
687- deprecated_self,
688- item. id ,
689- item. id ,
690- self_ty. span ,
691- ~"this method form is deprecated; use an explicit `self ` \
692- parameter or mark the method as static");
693- }
694- _ => {}
695- }
696- }
697-
698- match /*bad*/copy item.node {
699- ast::item_trait(_, _, methods) => {
700- for methods.each |method| {
701- match /*bad*/copy *method {
702- ast::required(ty_method) => {
703- maybe_warn(cx, item, ty_method.self_ty);
704- }
705- ast::provided(method) => {
706- maybe_warn(cx, item, method.self_ty);
707- }
708- }
709- }
710- }
711- ast::item_impl(_, _, _, methods) => {
712- for methods.each |method| {
713- maybe_warn(cx, item, method.self_ty);
714- }
715- }
716- _ => {}
717- }
718- }
719-
720671fn check_item_deprecated_mutable_fields ( cx : ty:: ctxt , item : @ast:: item ) {
721672 match item. node {
722673 ast:: item_struct( struct_def, _) => {
0 commit comments