From 967be9e750221ab2ab783f95df79bb26d290a45e Mon Sep 17 00:00:00 2001 From: Martial Simon Date: Mon, 15 Sep 2025 01:07:58 +0200 Subject: add: added projects --- tiger-compiler/src/ast/function-dec.hxx | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 tiger-compiler/src/ast/function-dec.hxx (limited to 'tiger-compiler/src/ast/function-dec.hxx') diff --git a/tiger-compiler/src/ast/function-dec.hxx b/tiger-compiler/src/ast/function-dec.hxx new file mode 100644 index 0000000..b9dda47 --- /dev/null +++ b/tiger-compiler/src/ast/function-dec.hxx @@ -0,0 +1,23 @@ +/** + ** \file ast/function-dec.hxx + ** \brief Inline methods of ast::FunctionDec. + */ + +#pragma once + +#include + +namespace ast +{ + + inline const VarChunk& FunctionDec::formals_get() const { return *formals_; } + inline VarChunk& FunctionDec::formals_get() { return *formals_; } + + inline const NameTy* FunctionDec::result_get() const { return result_; } + inline NameTy* FunctionDec::result_get() { return result_; } + + inline const Exp* FunctionDec::body_get() const { return body_; } + inline Exp* FunctionDec::body_get() { return body_; } + inline void FunctionDec::body_set(Exp* body) { body_ = body; } + +} // namespace ast -- cgit v1.2.3