[Issue 861] New: Using two typedefs of an undefined name in a class in a different module with import cycles causes DMD to hang

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Jan 20 12:38:51 PST 2007


http://d.puremagic.com/issues/show_bug.cgi?id=861

           Summary: Using two typedefs of an undefined name in a class in a
                    different module with import cycles causes DMD to hang
           Product: D
           Version: 1.00
          Platform: PC
        OS/Version: Windows
            Status: NEW
          Keywords: rejects-valid
          Severity: critical
          Priority: P2
         Component: DMD
        AssignedTo: bugzilla at digitalmars.com
        ReportedBy: deewiant at gmail.com


Like Issue 860, this bug is hard to summarize. Essentially, the problem is that
compiling the definesType module, below, causes DMD to hang with 100% CPU
usage.

--
module definesType;

import usesType; // import cycle

//alias int NONEXISTENT_NAME;
//typedef int NONEXISTENT_NAME;

typedef NONEXISTENT_NAME
        myTypedef,
        myTypedef2;
--
module usesType;

import definesType;

// must be class, not struct or template
class UsesTypedefs {
        // can be anything as long as both typedefs are used
        myTypedef usesTypedef;
        myTypedef2 usesTypedef2;
}
--

Uncommenting either the alias or the typedef (or even both) doesn't affect the
bug in any way (this may have something to do with Issue 860).


-- 



More information about the Digitalmars-d-bugs mailing list