Skip to content

cargo fix --edition-idioms: "failed to automatically apply fixes suggested by rustc to crate" #6273

@SimonSapin

Description

@SimonSapin
  • Clone Servo at commit 6878dbbbeaa59b21a7b3608b6d6a911e88c1e443 (current HEAD)
  • cd components/profile
  • cargo +nightly fix --edition-idioms

rustc 1.32.0-nightly (13dab66a6 2018-11-05)
cargo 1.32.0-nightly (1fa3088 2018-10-31)

    Checking profile v0.0.1 (/home/simon/servo/components/profile)                                                     
warning: failed to automatically apply fixes suggested by rustc to crate `profile`                                     

after fixes were automatically applied the compiler reported errors within these files:

  * components/profile/lib.rs

This likely indicates a bug in either rustc or cargo itself,
and we would appreciate a bug report! You're likely to see 
a number of compiler warnings after this message which cargo
attempted to fix but failed. If you could open an issue at
https://github.com/rust-lang/cargo/issues
quoting the full output of this command we'd be very appreciative!

warning: unused extern crate                                                                                           
 --> components/profile/lib.rs:9:1                                                                                     
  |                                                                                                                    
9 | extern crate influent;                                                                                             
  | ^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                             
  |                                                                                                                    
  = note: `-W unused-extern-crates` implied by `-W rust-2018-idioms`                                                   
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:10:1                                                                                   
   |                                                                                                                   
10 | extern crate ipc_channel;                                                                                         
   | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                         
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:14:1                                                                                   
   |                                                                                                                   
13 | / #[cfg(not(target_os = "windows"))]                                                                              
14 | | extern crate libc;                                                                                              
   | | ^^^^^^^^^^^^^^^^^-                                                                                              
   | |__________________|                                                                                              
   |                    help: remove it                                                                                
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:20:1                                                                                   
   |                                                                                                                   
19 | / #[cfg(target_os = "linux")]                                                                                     
20 | | extern crate regex;                                                                                             
   | | ^^^^^^^^^^^^^^^^^^-                                                                                             
   | |___________________|                                                                                             
   |                     help: remove it                                                                               
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:23:1                                                                                   
   |                                                                                                                   
23 | extern crate serde_json;                                                                                          
   | ^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                          
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:24:1                                                                                   
   |                                                                                                                   
24 | extern crate servo_config;                                                                                        
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                        
                                                                                                                       
warning: `extern crate` is not idiomatic in the new edition                                                            
  --> components/profile/lib.rs:27:1                                                                                   
   |                                                                                                                   
27 | extern crate time as std_time;                                                                                    
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: convert it to a `use`                                                        
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:28:1                                                                                   
   |                                                                                                                   
28 | extern crate tokio;                                                                                               
   | ^^^^^^^^^^^^^^^^^^^ help: remove it                                                                               
                                                                                                                       
warning: unused extern crate                                                                                           
 --> components/profile/lib.rs:9:1                                                                                     
  |                                                                                                                    
9 | extern crate influent;                                                                                             
  | ^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                             
  |                                                                                                                    
  = note: `-W unused-extern-crates` implied by `-W rust-2018-idioms`                                                   
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:10:1                                                                                   
   |                                                                                                                   
10 | extern crate ipc_channel;                                                                                         
   | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                         
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:14:1                                                                                   
   |                                                                                                                   
13 | / #[cfg(not(target_os = "windows"))]                                                                              
14 | | extern crate libc;                                                                                              
   | | ^^^^^^^^^^^^^^^^^-                                                                                              
   | |__________________|                                                                                              
   |                    help: remove it                                                                                
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:20:1                                                                                   
   |                                                                                                                   
19 | / #[cfg(target_os = "linux")]                                                                                     
20 | | extern crate regex;                                                                                             
   | | ^^^^^^^^^^^^^^^^^^-                                                                                             
   | |___________________|                                                                                             
   |                     help: remove it                                                                               
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:23:1                                                                                   
   |                                                                                                                   
23 | extern crate serde_json;                                                                                          
   | ^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                          
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:24:1                                                                                   
   |                                                                                                                   
24 | extern crate servo_config;                                                                                        
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove it                                                                        
                                                                                                                       
warning: `extern crate` is not idiomatic in the new edition                                                            
  --> components/profile/lib.rs:27:1                                                                                   
   |                                                                                                                   
27 | extern crate time as std_time;                                                                                    
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: convert it to a `use`                                                        
                                                                                                                       
warning: unused extern crate                                                                                           
  --> components/profile/lib.rs:28:1                                                                                   
   |                                                                                                                   
28 | extern crate tokio;                                                                                               
   | ^^^^^^^^^^^^^^^^^^^ help: remove it                                                                               
                                                                                                                       
    Finished dev [unoptimized + debuginfo] target(s) in 1.62s                                                          

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions