www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - Compiler bug

reply David Medlock <amedlock nospam.org> writes:
The following function has the wrong return type, but crashes the compiler:


static int[1][5] array = [[1],[2],[3],[4],[5] ];



void Lookup( int which )
{
   switch( which )
   {
     case 0 : return array[which];
   }
}


Internal error: ..\ztc\cgcod.c 1445
May 04 2005
next sibling parent Thomas Kuehne <thomas-dloop kuehne.thisisspam.cn> writes:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

David Medlock schrieb am Wed, 04 May 2005 13:53:46 -0400:
 The following function has the wrong return type, but crashes the compiler:


 static int[1][5] array = [[1],[2],[3],[4],[5] ];



 void Lookup( int which )
 {
    switch( which )
    {
      case 0 : return array[which];
    }
 }


 Internal error: ..\ztc\cgcod.c 1445
Are you using DMD-0.119 or older? Thomas -----BEGIN PGP SIGNATURE----- iD8DBQFCezq63w+/yD4P9tIRAn5pAKCn7jHIqg19QppaK9RHHFUv0Um4UQCgpIlW Wq+R4rL4Gufwku/kHg0XVLY= =/+cm -----END PGP SIGNATURE-----
May 06 2005
prev sibling parent reply "Walter" <newshound digitalmars.com> writes:
I can't reproduce the problem.
May 07 2005
parent reply David Medlock <noone nowhere.com> writes:
Walter wrote:
 I can't reproduce the problem.
 
 
Sorry, I forgot DMD 119 was on my machine at work....looks like you fixed this already. I would have responded sooner but my second child was born 5/5/05, baby girl 7 lbs 6.6 oz. =D -DavidM
May 09 2005
next sibling parent Derek Parnell <derek psych.ward> writes:
On Mon, 09 May 2005 23:42:44 -0400, David Medlock wrote:


 I would have responded sooner but my second child was born 5/5/05, baby 
 girl 7 lbs 6.6 oz.
That's great! Congrats and all that. My second was a girl too - she's ten now! -- Derek Melbourne, Australia 10/05/2005 1:57:06 PM
May 09 2005
prev sibling parent "Walter" <newshound digitalmars.com> writes:
"David Medlock" <noone nowhere.com> wrote in message
news:d5pajg$9pp$1 digitaldaemon.com...
 I would have responded sooner but my second child was born 5/5/05, baby
 girl 7 lbs 6.6 oz.
I think we'll allow that excuse <g>. Congratulations!
May 11 2005