www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - internal error

reply "Bent Rasmussen" <exo bent-rasmussen.info> writes:
DMD 0.92 (XP/SP) chokes on this

struct test {
}

void rec(int n, test t) {
 if (n > 0) {
  rec(n-1,t);
 }
}

"Internal error: ..\ztc\blockopt.c 1941"

If "test t" becomes "int t", there is no problem.

Is there a problem with recursive application of struct parameters?
Or have I missed something obvious?
Jun 20 2004
parent "Walter" <newshound digitalmars.com> writes:
It should work. I'll add it to the bug list.

"Bent Rasmussen" <exo bent-rasmussen.info> wrote in message
news:cb550t$1pon$1 digitaldaemon.com...
 DMD 0.92 (XP/SP) chokes on this

 struct test {
 }

 void rec(int n, test t) {
  if (n > 0) {
   rec(n-1,t);
  }
 }

 "Internal error: ..\ztc\blockopt.c 1941"

 If "test t" becomes "int t", there is no problem.

 Is there a problem with recursive application of struct parameters?
 Or have I missed something obvious?

Jun 20 2004