RE:*p[0] bug

Masaharu Goto (MXJ02154@nifty.ne.jp)
Fri, 24 Jul 1998 23:32:00 +0900


Federico,

I think I fixed the bug you reported in cint5.13.66.

Masaharu Goto

-----------------------------
void Check(Float_t *p[])
{
printf("p02 = %d %f\n",p[0],*p[0]);
p[0]--;
printf("p01 = %d %f\n",p[0],*p[0]);
//
// So far so good...
//
(*p[0]) = 7;
printf("p01 = %d %f\n",p[0],*p[0]); // and here it crushes!!

}

This works as expected. But if you remove the brackets around *p[0] used
as an lvalue, is p[0] which is assigned the value of 7, and the next line
bombs. Note that *p[0] works well as a left value few lines above in the
main program, but NOT in the procedure check. Any hint? Thanks,