summaryrefslogtreecommitdiff
path: root/tiger-compiler/src/type/method.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'tiger-compiler/src/type/method.hxx')
-rw-r--r--tiger-compiler/src/type/method.hxx27
1 files changed, 27 insertions, 0 deletions
diff --git a/tiger-compiler/src/type/method.hxx b/tiger-compiler/src/type/method.hxx
new file mode 100644
index 0000000..d026252
--- /dev/null
+++ b/tiger-compiler/src/type/method.hxx
@@ -0,0 +1,27 @@
+/**
+ ** \file type/method.hxx
+ ** \brief Inline methods for type::Method.
+ */
+#pragma once
+
+namespace type
+{
+ inline misc::symbol Method::name_get() const { return name_; }
+
+ inline const Class* Method::owner_get() const { return owner_; }
+
+ inline const Type& Method::type_get() const
+ {
+ // FIXME DONE: Some code was deleted here.
+ return *def_->type_get();
+ }
+
+ inline const ast::MethodDec* Method::def_get() const { return def_; }
+
+ inline ast::MethodDec* Method::def_get() { return def_; }
+
+ inline void Method::name_set(misc::symbol name) { name_ = name; }
+
+ inline void Method::def_set(ast::MethodDec* def) { def_ = def; }
+
+} // namespace type