Skip to content

Commit 740b85b

Browse files
authored
Merge pull request #37 from aya-rs/appease-clippy
appease `clippy::uninlined-format-args`
2 parents d0cbf35 + 941ef97 commit 740b85b

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

build.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -292,8 +292,7 @@ mod llvm {
292292
let other_mod_path =
293293
quote! { #(#other_mod_path::)*#ident };
294294
panic!(
295-
"duplicate function `{}` `{}`",
296-
mod_path, other_mod_path
295+
"duplicate function `{mod_path}` `{other_mod_path}`"
297296
);
298297
}
299298
Entry::Vacant(entry) => {

src/init.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ fn arch2backend(arch: &str) -> String {
3131
"powerpc" | "powerpc64" => "PowerPC".into(),
3232
"sparc" | "sparc64" => "Sparc".into(),
3333
"x86" | "x86_64" => "X86".into(),
34-
_ => panic!("Unknown backend: {}", arch),
34+
_ => panic!("Unknown backend: {arch}"),
3535
}
3636
}
3737

@@ -42,7 +42,7 @@ fn get_native_backend() -> String {
4242

4343
unsafe fn init_all(postfix: &str) {
4444
for backend in POSSIBLE_BACKENDS {
45-
let name = format!("LLVMInitialize{}{}", backend, postfix);
45+
let name = format!("LLVMInitialize{backend}{postfix}");
4646
if let Ok(entrypoint) = SHARED_LIB.get::<unsafe extern "C" fn()>(name.as_bytes()) {
4747
entrypoint();
4848
}
@@ -72,7 +72,7 @@ pub unsafe extern "C" fn LLVM_InitializeAllAsmPrinters() {
7272

7373
unsafe fn init_native(postfix: &str) -> LLVMBool {
7474
let backend = get_native_backend();
75-
let name = format!("LLVMInitialize{}{}", backend, postfix);
75+
let name = format!("LLVMInitialize{backend}{postfix}");
7676
if let Ok(entrypoint) = SHARED_LIB.get::<unsafe extern "C" fn()>(name.as_bytes()) {
7777
entrypoint();
7878
0

0 commit comments

Comments
 (0)