www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 6771] New: Jagged array and init causing DMD to take a LONG time to compile.

reply d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6771

           Summary: Jagged array and init causing DMD to take a LONG time
                    to compile.
           Product: D
           Version: D2
          Platform: x86_64
        OS/Version: Windows
            Status: NEW
          Severity: major
          Priority: P2
         Component: DMD
        AssignedTo: nobody puremagic.com
        ReportedBy: damianday hotmail.co.uk



const MAXX = 40;
const MAXY = 40;

struct MyStruct
{
   ushort Var1;
   ushort Var2;
   ushort Var3;
   // NOTE: comment out these variables below and it
   // will compile faster..
   ubyte Var4;
   ubyte Var5;
   ubyte Var6;
   ubyte Var7;
   ubyte Var8;
   ubyte Var9;
}

public class MyClass
{
   public MyStruct[MAXX * 3][MAXY * 3] MArr;

   public this()
   {
      MArr = MArr.init; // <-- THIS LINE
   }
}

The above source code will cause the DMD compiler to take a long time to
compile (minutes? hours?). Commenting out the lines suggested will speed the
compilation up enough to see it succeed.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Oct 05 2011
next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6771


yebblies <yebblies gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |yebblies gmail.com
           Platform|x86_64                      |All
         Resolution|                            |DUPLICATE
         OS/Version|Windows                     |All



*** This issue has been marked as a duplicate of issue 2396 ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Feb 01 2012
prev sibling next sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6771




*** This issue has been marked as a duplicate of issue 8828 ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Mar 12 2013
prev sibling parent d-bugmail puremagic.com writes:
http://d.puremagic.com/issues/show_bug.cgi?id=6771


Martin Nowak <code dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |code dawg.eu



*** This issue has been marked as a duplicate of issue 2396 ***

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
Mar 12 2013