diff --git a/compiler2/ttcn3/AST_ttcn3.cc b/compiler2/ttcn3/AST_ttcn3.cc index 0bbdd64758e899e13a5bad27357cb42c70aad127..a37e008b8090d021fed183bf5d07a342d6c01275 100644 --- a/compiler2/ttcn3/AST_ttcn3.cc +++ b/compiler2/ttcn3/AST_ttcn3.cc @@ -5548,7 +5548,7 @@ namespace Ttcn { char* Def_Exception::generate_code_str(char *str) { - return mputprintf(str, "EXCEPTION<%s>& %s = static_cast<EXCEPTION<%s>&>(exc_base);\n", + return mputprintf(str, "EXCEPTION< %s >& %s = static_cast<EXCEPTION< %s >&>(exc_base);\n", type->get_genname_value(my_scope).c_str(), id->get_name().c_str(), type->get_genname_value(my_scope).c_str()); } diff --git a/compiler2/ttcn3/Statement.cc b/compiler2/ttcn3/Statement.cc index 8b97d8fd14798c890bfe253b0aa9458763f80ed4..b606bc4926fd1542e1feca2ced775c4d3524de2a 100644 --- a/compiler2/ttcn3/Statement.cc +++ b/compiler2/ttcn3/Statement.cc @@ -8569,7 +8569,7 @@ error: str = mputprintf(str, "%s[%i] = \"%s\";\n", id_str.c_str(), i, t != NULL ? t->get_exception_name().c_str() : "object"); } - str = mputprintf(str, "throw EXCEPTION<%s>(new %s(%s), %s, %i);\n", + str = mputprintf(str, "throw EXCEPTION< %s >(new %s(%s), %s, %i);\n", exc_type_str.c_str(), exc_type_str.c_str(), expr.expr, id_str.c_str(), nof_exc_types); if (expr.postamble != NULL) { str = mputstr(str, expr.postamble);