From ab1d1ecba4f2562a8b81d887d08370d5fcf0921d Mon Sep 17 00:00:00 2001 From: Syndamia Date: Sun, 29 Jan 2023 20:58:52 +0200 Subject: [IPL/T] Added current progress of implementing functions --- .../Transpiler/src/Value/Name.cpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 Year 2/Implementation of Programming Languages/Transpiler/src/Value/Name.cpp (limited to 'Year 2/Implementation of Programming Languages/Transpiler/src/Value/Name.cpp') diff --git a/Year 2/Implementation of Programming Languages/Transpiler/src/Value/Name.cpp b/Year 2/Implementation of Programming Languages/Transpiler/src/Value/Name.cpp new file mode 100644 index 0000000..52094b9 --- /dev/null +++ b/Year 2/Implementation of Programming Languages/Transpiler/src/Value/Name.cpp @@ -0,0 +1,17 @@ +#include "Name.h" +#include "Value.h" +#include "../LLVMVisitor/LLVMVisitor.h" + +const std::string& Name::get_value() const { + return val; +} + +std::string Name::Visit(LLVMVisitor& visitor) const { + return visitor.Visit(*this); +} + +Value::T_Primitive Name::RetType() const { + return T_name; +} + +Name::Name(std::string val) : val(val) {} -- cgit v1.3.1-23-gd82d