aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/go/gofrontend/types.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/go/gofrontend/types.cc b/gcc/go/gofrontend/types.cc
index 13cd48a..61ec555 100644
--- a/gcc/go/gofrontend/types.cc
+++ b/gcc/go/gofrontend/types.cc
@@ -2595,7 +2595,7 @@ Integer_type::do_get_backend(Gogo* gogo)
Expression*
Integer_type::do_type_descriptor(Gogo* gogo, Named_type* name)
{
- go_assert(name != NULL);
+ go_assert(name != NULL || saw_errors());
return this->plain_type_descriptor(gogo, this->runtime_type_kind_, name);
}
@@ -2730,7 +2730,7 @@ Float_type::do_get_backend(Gogo* gogo)
Expression*
Float_type::do_type_descriptor(Gogo* gogo, Named_type* name)
{
- go_assert(name != NULL);
+ go_assert(name != NULL || saw_errors());
return this->plain_type_descriptor(gogo, this->runtime_type_kind_, name);
}
@@ -2857,7 +2857,7 @@ Complex_type::do_get_backend(Gogo* gogo)
Expression*
Complex_type::do_type_descriptor(Gogo* gogo, Named_type* name)
{
- go_assert(name != NULL);
+ go_assert(name != NULL || saw_errors());
return this->plain_type_descriptor(gogo, this->runtime_type_kind_, name);
}