From 5fca81c68e3a741b3205397081c73ceb303a4ebd Mon Sep 17 00:00:00 2001 From: lyken Date: Tue, 27 Aug 2024 17:19:24 +0800 Subject: [PATCH] CallFunction -> FnCall --- nac3core/src/codegen/model/function.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/nac3core/src/codegen/model/function.rs b/nac3core/src/codegen/model/function.rs index 0b9d4d37..62e9f25f 100644 --- a/nac3core/src/codegen/model/function.rs +++ b/nac3core/src/codegen/model/function.rs @@ -35,7 +35,7 @@ struct Arg<'ctx> { /// If `my_function_name` has not been declared in `ctx.module`, once `.returning()` is called, a function /// declaration of `my_function_name` is added to `ctx.module`, where the [`FunctionType`] is deduced from /// the argument types and returning type. -pub struct CallFunction<'ctx, 'a, 'b, 'c, 'd, G: CodeGenerator + ?Sized> { +pub struct FnCall<'ctx, 'a, 'b, 'c, 'd, G: CodeGenerator + ?Sized> { generator: &'d mut G, ctx: &'b CodeGenContext<'ctx, 'a>, /// Function name @@ -46,9 +46,9 @@ pub struct CallFunction<'ctx, 'a, 'b, 'c, 'd, G: CodeGenerator + ?Sized> { attrs: Vec<&'static str>, } -impl<'ctx, 'a, 'b, 'c, 'd, G: CodeGenerator + ?Sized> CallFunction<'ctx, 'a, 'b, 'c, 'd, G> { +impl<'ctx, 'a, 'b, 'c, 'd, G: CodeGenerator + ?Sized> FnCall<'ctx, 'a, 'b, 'c, 'd, G> { pub fn begin(generator: &'d mut G, ctx: &'b CodeGenContext<'ctx, 'a>, name: &'c str) -> Self { - CallFunction { generator, ctx, name, args: Vec::new(), attrs: Vec::new() } + FnCall { generator, ctx, name, args: Vec::new(), attrs: Vec::new() } } /// Push a list of LLVM function attributes to the function declaration.