Detect recursive type definition like
"type T0 T1; type T1 T2; ...... type Tn T0".
Fixes golang/go#25320.
Reviewed-on: https://go-review.googlesource.com/c/159837
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@268347
138bc75d-0d04-0410-961f-
82ee72b054a4
-d67c4bf0c42b79d54925ba8c5f23278ee6c3efb6
+5ccb2d8593963e06ec3a35d362b384e82301d9f0
The first line of this file holds the git revision number of the last
merge done from the gofrontend repository.
break;
case Type::TYPE_NAMED:
+ if (type->named_type() == type->base()->named_type())
+ {
+ this->found_ = true;
+ return TRAVERSE_EXIT;
+ }
+ else
+ go_assert(saw_errors());
+ break;
+
case Type::TYPE_FORWARD:
go_assert(saw_errors());
break;