From ca1395aed6e7544c3af8f28415fdcc61e19c3dd9 Mon Sep 17 00:00:00 2001 From: David Mak Date: Wed, 21 Aug 2024 14:42:44 +0800 Subject: [PATCH] [core] codegen: Remove redundant return --- nac3core/src/codegen/mod.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/nac3core/src/codegen/mod.rs b/nac3core/src/codegen/mod.rs index f46b50d92..71a2d52a4 100644 --- a/nac3core/src/codegen/mod.rs +++ b/nac3core/src/codegen/mod.rs @@ -580,11 +580,11 @@ fn get_llvm_abi_type<'ctx, G: CodeGenerator + ?Sized>( ) -> BasicTypeEnum<'ctx> { // If the type is used in the definition of a function, return `i1` instead of `i8` for ABI // consistency. - return if unifier.unioned(ty, primitives.bool) { + if unifier.unioned(ty, primitives.bool) { ctx.bool_type().into() } else { get_llvm_type(ctx, module, generator, unifier, top_level, type_cache, ty) - }; + } } /// Whether `sret` is needed for a return value with type `ty`.