File tree Expand file tree Collapse file tree 5 files changed +14
-30
lines changed Expand file tree Collapse file tree 5 files changed +14
-30
lines changed Original file line number Diff line number Diff line change 8
8
// option. This file may not be copied, modified, or distributed
9
9
// except according to those terms.
10
10
11
- extern crate env_logger;
11
+ use env_logger;
12
12
#[ macro_use]
13
13
extern crate failure;
14
- extern crate getopts ;
15
- extern crate rustfmt_nightly as rustfmt;
14
+
15
+ use rustfmt_nightly as rustfmt;
16
16
17
17
use std:: env;
18
18
use std:: fs:: File ;
@@ -296,7 +296,7 @@ fn format(
296
296
Ok ( exit_code)
297
297
}
298
298
299
- fn format_and_emit_report < T : Write > ( session : & mut Session < T > , input : Input ) {
299
+ fn format_and_emit_report < T : Write > ( session : & mut Session < ' _ , T > , input : Input ) {
300
300
match session. format ( input) {
301
301
Ok ( report) => {
302
302
if report. has_warnings ( ) {
Original file line number Diff line number Diff line change 13
13
#![ cfg( not( test) ) ]
14
14
#![ deny( warnings) ]
15
15
16
- extern crate cargo_metadata;
17
- extern crate getopts;
18
- extern crate serde_json as json ;
16
+ use cargo_metadata;
17
+ use getopts;
18
+
19
19
20
20
use std:: collections:: { HashMap , HashSet } ;
21
21
use std:: env;
Original file line number Diff line number Diff line change 14
14
15
15
#![ deny( warnings) ]
16
16
17
- extern crate env_logger;
17
+ use env_logger;
18
18
#[ macro_use]
19
19
extern crate failure;
20
- extern crate getopts;
20
+ use getopts;
21
21
#[ macro_use]
22
22
extern crate log;
23
- extern crate regex;
23
+ use regex;
24
24
#[ macro_use]
25
25
extern crate serde_derive;
26
- extern crate serde_json as json;
26
+ use serde_json as json;
27
27
28
28
use std:: collections:: HashSet ;
29
29
use std:: io:: { self , BufRead } ;
Original file line number Diff line number Diff line change 8
8
// option. This file may not be copied, modified, or distributed
9
9
// except according to those terms.
10
10
11
- extern crate env_logger;
12
- extern crate getopts ;
11
+ use env_logger;
12
+
13
13
#[ macro_use]
14
14
extern crate log;
15
- extern crate rustfmt_nightly as rustfmt;
15
+ use rustfmt_nightly as rustfmt;
16
16
17
17
use std:: env;
18
18
use std:: io:: stdout;
Original file line number Diff line number Diff line change 10
10
11
11
#[ macro_use]
12
12
extern crate derive_new;
13
- extern crate atty;
14
- extern crate bytecount;
15
- extern crate diff;
16
- extern crate dirs;
17
- extern crate failure;
18
- extern crate itertools;
19
13
#[ cfg( test) ]
20
14
#[ macro_use]
21
15
extern crate lazy_static;
22
16
#[ macro_use]
23
17
extern crate log;
24
- extern crate regex;
25
- extern crate rustc_target;
26
- extern crate serde;
27
18
#[ macro_use]
28
19
extern crate serde_derive;
29
- extern crate serde_json;
30
- extern crate syntax;
31
- extern crate syntax_pos;
32
- extern crate toml;
33
- extern crate unicode_categories;
34
- extern crate unicode_segmentation;
35
- extern crate unicode_width;
36
20
37
21
use std:: cell:: RefCell ;
38
22
use std:: collections:: HashMap ;
You can’t perform that action at this time.
0 commit comments