https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109264

            Bug ID: 109264
           Summary: Compiler hangs trying to resolve opaque type
           Product: gcc
           Version: 13.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: modula2
          Assignee: gaius at gcc dot gnu.org
          Reporter: gaius at gcc dot gnu.org
  Target Milestone: ---

Created attachment 54736
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=54736&action=edit
Test module which provokes the bug

gm2 hangs if it compiles a module using an opaque type whose implementation
module contains a set.  For example see attachment and the following library
files:

DEFINITION MODULE stressset ;

TYPE
   dataType ;

END stressset.

----o<----o<----o<----o<----o<----o<----o<

IMPLEMENTATION MODULE stressset ;

TYPE
   enum = (red, blue, green) ;

CONST
   (* max = ORD (MAX (enum)) + 1 ; *)
   max = MAX (enum) + 1 ;


TYPE
   dataType = POINTER TO RECORD
                            next    : dataType ;
                            contents: ARRAY [0..max] OF CARDINAL ;
                            set     : SET OF enum ;
                         END ;

END stressset.

Reply via email to