File tree 3 files changed +10
-7
lines changed
3 files changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -42,8 +42,8 @@ extern crate flate;
42
42
extern crate getopts;
43
43
extern crate graphviz;
44
44
extern crate libc;
45
- extern crate " rustc_llvm" as llvm ;
46
- extern crate "rustc_back" as rustc_back;
45
+ extern crate rustc_llvm;
46
+ extern crate rustc_back;
47
47
extern crate serialize;
48
48
extern crate rbml;
49
49
extern crate time;
@@ -53,6 +53,8 @@ extern crate time;
53
53
#[ cfg( test) ]
54
54
extern crate test;
55
55
56
+ pub use rustc_llvm as llvm;
57
+
56
58
mod diagnostics;
57
59
58
60
pub mod back {
Original file line number Diff line number Diff line change @@ -36,6 +36,7 @@ pub enum ObsoleteSyntax {
36
36
ObsoleteManagedExpr ,
37
37
ObsoleteImportRenaming ,
38
38
ObsoleteSubsliceMatch ,
39
+ ObsoleteExternCrateRenaming ,
39
40
}
40
41
41
42
pub trait ParserObsoleteMethods {
@@ -92,6 +93,10 @@ impl<'a> ParserObsoleteMethods for parser::Parser<'a> {
92
93
ObsoleteSubsliceMatch => (
93
94
"subslice match syntax" ,
94
95
"instead of `..xs`, write `xs..` in a pattern"
96
+ ) ,
97
+ ObsoleteExternCrateRenaming => (
98
+ "`extern crate foo = bar` syntax" ,
99
+ "write `extern crate bar as foo` instead"
95
100
)
96
101
} ;
97
102
Original file line number Diff line number Diff line change @@ -4783,11 +4783,7 @@ impl<'a> Parser<'a> {
4783
4783
self . bump ( ) ;
4784
4784
let path = self . parse_str ( ) ;
4785
4785
let span = self . span ;
4786
- self . span_warn ( span,
4787
- format ! ( "this extern crate syntax is deprecated. \
4788
- Use: extern crate \" {}\" as {};",
4789
- path. ref0( ) . get( ) , the_ident. as_str( ) ) . as_slice ( )
4790
- ) ;
4786
+ self . obsolete ( span, ObsoleteExternCrateRenaming ) ;
4791
4787
Some ( path)
4792
4788
} else { None } ;
4793
4789
You can’t perform that action at this time.
0 commit comments