rustc: Remove deprecated lint names

These were all renamed quite some time ago, so remove their old names from the
compiler.
This commit is contained in:
Alex Crichton 2015-01-20 11:20:22 -08:00
parent 953f294ea3
commit 64914d9d39
6 changed files with 6 additions and 45 deletions

View File

@ -231,30 +231,7 @@ impl LintStore {
// We have one lint pass defined in this module.
self.register_pass(sess, false, box GatherNodeLevels as LintPassObject);
// Insert temporary renamings for a one-time deprecation (#16545)
self.register_renamed("unnecessary_typecast", "unused_typecasts");
self.register_renamed("unsigned_negate", "unsigned_negation");
self.register_renamed("type_limits", "unused_comparisons");
self.register_renamed("type_overflow", "overflowing_literals");
self.register_renamed("ctypes", "improper_ctypes");
self.register_renamed("owned_heap_memory", "box_pointers");
self.register_renamed("unused_attribute", "unused_attributes");
self.register_renamed("path_statement", "path_statements");
self.register_renamed("unused_result", "unused_results");
self.register_renamed("non_uppercase_statics", "non_upper_case_globals");
self.register_renamed("unnecessary_parens", "unused_parens");
self.register_renamed("unnecessary_import_braces", "unused_import_braces");
self.register_renamed("unsafe_block", "unsafe_blocks");
self.register_renamed("unnecessary_allocation", "unused_allocation");
self.register_renamed("missing_doc", "missing_docs");
self.register_renamed("unused_extern_crate", "unused_extern_crates");
self.register_renamed("unnecessary_qualification", "unused_qualifications");
self.register_renamed("unrecognized_lint", "unknown_lints");
self.register_renamed("unused_variable", "unused_variables");
self.register_renamed("dead_assignment", "unused_assignments");
self.register_renamed("unknown_crate_type", "unknown_crate_types");
self.register_renamed("variant_size_difference", "variant_size_differences");
self.register_renamed("transmute_fat_ptr", "fat_ptr_transmutes");
// Insert temporary renamings for a one-time deprecation
self.register_renamed("raw_pointer_deriving", "raw_pointer_derive");
}

View File

@ -1,16 +0,0 @@
// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// Check that lint deprecation works
#[deny(unused_variable)] //~ warning: lint unused_variable has been renamed to unused_variables
pub fn main() {
let x = 0u8; //~ error: unused variable:
}

View File

@ -10,7 +10,7 @@
#![allow(dead_code)]
// compile-flags: -D type-limits
// compile-flags: -D unused-comparisons
fn main() { }
fn foo() {

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// compile-flags: -D path-statement
// compile-flags: -D path-statements
fn main() {
let x = 10is;

View File

@ -8,7 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// compile-flags:--crate-name crate-name-attr-used -F unused-attribute
// compile-flags:--crate-name crate-name-attr-used -F unused-attributes
#![crate_name = "crate-name-attr-used"]

View File

@ -8,9 +8,9 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.
// compile-flags:-D ctypes
// compile-flags:-D improper-ctypes
#![allow(ctypes)]
#![allow(improper_ctypes)]
mod libc {
extern {