aboutsummaryrefslogtreecommitdiffstats
path: root/c_compiler/include/function.hpp
diff options
context:
space:
mode:
authorYann Herklotz <ymherklotz@gmail.com>2017-03-03 23:45:47 +0000
committerYann Herklotz <ymherklotz@gmail.com>2017-03-03 23:45:47 +0000
commit6b7f5137edb18372bc3e3076dab1cb45c8e4c2ec (patch)
tree70e16653c924e2955322fb8f461ddc75cedc10b7 /c_compiler/include/function.hpp
parent46c70f9c2dca832ba84472dbbe09064b57710b45 (diff)
downloadCompiler-6b7f5137edb18372bc3e3076dab1cb45c8e4c2ec.tar.gz
Compiler-6b7f5137edb18372bc3e3076dab1cb45c8e4c2ec.zip
Printing right way
Diffstat (limited to 'c_compiler/include/function.hpp')
-rw-r--r--c_compiler/include/function.hpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/c_compiler/include/function.hpp b/c_compiler/include/function.hpp
index a6d44f0..cb68b2f 100644
--- a/c_compiler/include/function.hpp
+++ b/c_compiler/include/function.hpp
@@ -16,7 +16,8 @@ public:
virtual void print() const {
std::cout << id << std::endl;
- parameter_list->print();
+ if(parameter_list != nullptr)
+ parameter_list->print();
}
virtual void printxml() const {}