On Mon, Dec 31, 2001 at 07:06:46AM +0200, Jarkko Hietaniemi wrote: > On Sun, Dec 30, 2001 at 07:04:40PM -0500, Michael G Schwern wrote: > > Those lovely warnings the OSF compiler generates are in the attached log. > > cc: Warning: sv.c, line 5703: In this statement, the referenced type of the pointer >value "((char ...)ptr)" is "char", which is not compatible with "unsigned char" >because they differ by signed/unsigned attribute. (ptrmismatch1) > PerlIO_set_ptrcnt(fp, (STDCHAR*)ptr, cnt); /* deregisterize cnt and ptr */ > --------^ > cc: Warning: sv.c, line 5748: In this statement, the referenced type of the pointer >value "((char ...)ptr)" is "char", which is not compatible with "unsigned char" >because they differ by signed/unsigned attribute. (ptrmismatch1) > PerlIO_set_ptrcnt(fp, (STDCHAR*)ptr, cnt); /* put these back or we're in >trouble */ > ----^ > cc: Warning: str.c, line 302: In this statement, the referenced type of the pointer >value "((fp)->_ptr)" is "unsigned char", which is not compatible with "char" because >they differ by signed/unsigned attribute. (ptrmismatch1) > ptr = FILE_ptr(fp); /* reregisterize cnt and ptr */ > --------^ > cc: Warning: str.c, line 319: In this statement, the referenced type of the pointer >value "(char ...)ptr" is "char", which is not compatible with "unsigned char" because >they differ by signed/unsigned attribute. (ptrmismatch1) > FILE_ptr(fp) = (STDCHAR*)ptr; > ----^ > > I have vague memory of staring at these and IIRC no canna fixa without > introducing LHS casts, which again makes HP-UX grumpy.
Is the problem because Configure is only testing whether stdio's buffers are "unsigned char" or not? And replacing it with a 3 way test ["unsigned"/""/"signed"] would allow PerlIO to be built with the identical char and appease the very exacting OSF compiler?] I'm thinking about the numconvert tests. I'm thinking it's printf. [aside, to MJD I think, yes the final C99 spec does say that %E exponents should be only 2 digits if 2 will do it, so MS's 1E001 (or whatever their 3 digit was) isn't conforming. It would seem that MS didn't manage to change things from the draft to get the number of digits implementation dependent] [just like signed char not being signed int. Don't you just love committees and compromises? :-(] Nicholas Clark
