From 7120ab7b13ae926b5ac1680e2b0180c664aff8de Mon Sep 17 00:00:00 2001 From: Nick Gasson Date: Mon, 9 Jun 2008 12:54:21 +0100 Subject: [PATCH] Expression type might be null in some cases --- tgt-vhdl/vhdl_syntax.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tgt-vhdl/vhdl_syntax.cc b/tgt-vhdl/vhdl_syntax.cc index 12e9d4afb..a4841f762 100644 --- a/tgt-vhdl/vhdl_syntax.cc +++ b/tgt-vhdl/vhdl_syntax.cc @@ -315,7 +315,8 @@ void vhdl_signal_decl::emit(std::ofstream &of, int level) const vhdl_expr::~vhdl_expr() { - delete type_; + if (type != NULL) + delete type_; } /*