[12299] in Athena Bugs

home help back first fref pref prev next nref lref last post

rsaix 7.7C: cc

daemon@ATHENA.MIT.EDU (David E Evans)
Fri Jul 29 02:58:56 1994

To: bugs@MIT.EDU
Date: Fri, 29 Jul 1994 02:58:51 EDT
From: David E Evans <deevans@MIT.EDU>

System name:		w20-575-105
Type and version:	POWER 7.7C
Display type:		POWER_Gt1

What were you trying to do?
	compile a program

What's wrong:
	internal compiler error

What should have happened:
	it should have compiled

Please describe any relevant documentation references:
	these bug report forms could really use some work!
	the questions are not very significant.

	You probably want to know something about the code I
	was compiling, and how this effects the bug.
	Here is an excerpt of leafList.c:

leafList 
leafList_copy (leafList s)
{
  leafList r = leafList_new ();

  { int ind; 
    leaf *elements_ptr = s->elements; 
    for (ind = 0 ; ind < s->nelements; ind++) 
/* line 193 */      { leaf x = *(elements_ptr++);
	leafList_addh (r, x);
      }
  }

  return r;
}	
	
I compile with cc -c -IHeaders leafList.c:

cc -c -IHeaders leafList.c
"leafList.c", line 193.0: 1506-001 (U) INTERNAL COMPILER ERROR: Procedure TYPOPCOD:.
    1506-163: (S) Error recovery not possible. Compilation ended.
cc: 1501-230 Internal compiler error; please contact your IBM representative

Compilation exited abnormally with code 40 at Fri Jul 29 02:56:07

Now, I change the code to separate the ++:

  { int ind; 
    leaf *elements_ptr = s->elements; 
    for (ind = 0 ; ind < s->nelements; ind++) 
      { leaf x = *elements_ptr;  /* changed this line */
	elements_ptr++;          /* added this line */
	leafList_addh (r, x);
      }
  }

and it compiles fine with no errors.

--- Dave




home help back first fref pref prev next nref lref last post