From 1f8b75b5494aaa3ada072ea4303b6aeec7734e08 Mon Sep 17 00:00:00 2001 From: Toshiki Teramura Date: Tue, 31 Dec 2019 19:32:54 +0900 Subject: [PATCH 1/2] Format --- src/lib.rs | 2 +- src/path.rs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index 428995f..8b61026 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -76,10 +76,10 @@ pub mod proxy { use llvm_sys::analysis::*; use llvm_sys::debuginfo::*; - use llvm_sys::execution_engine::*; use llvm_sys::disassembler::*; use llvm_sys::error::*; use llvm_sys::error_handling::*; + use llvm_sys::execution_engine::*; use llvm_sys::link_time_optimizer::*; use llvm_sys::lto::*; use llvm_sys::object::*; diff --git a/src/path.rs b/src/path.rs index 8b5c3a7..1ce352d 100644 --- a/src/path.rs +++ b/src/path.rs @@ -89,7 +89,8 @@ fn collect_possible_paths() -> Result, Error> { cargo_path.pop(); if let Some(toolchain) = cargo_path.file_name() { - let arch = env::var("HOST").unwrap_or_else(|_| extract_arch(toolchain.to_str().unwrap())); + let arch = + env::var("HOST").unwrap_or_else(|_| extract_arch(toolchain.to_str().unwrap())); paths.push( cargo_path From 74424a5eb8d0b09db37d4eb0a67da312df812dcf Mon Sep 17 00:00:00 2001 From: Toshiki Teramura Date: Tue, 31 Dec 2019 19:40:35 +0900 Subject: [PATCH 2/2] Trim end comma --- build.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/build.rs b/build.rs index 57c1d7c..d0e8281 100644 --- a/build.rs +++ b/build.rs @@ -118,7 +118,9 @@ mod llvm { writeln!( file, "create_proxy!({}; {}; {});", - decl.name, decl.ret_ty, decl.args + decl.name, + decl.ret_ty, + decl.args.trim_end_matches(",") )?; }