DragonFly BSD
DragonFly commits List (threaded) for 2005-07
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: cvs commit: src/include ctype.h src/lib/libc/gen isctype.c tolower.c toupper.c


From: Matthew Dillon <dillon@xxxxxxxxxxxxxxxxxxxx>
Date: Fri, 8 Jul 2005 11:30:06 -0700 (PDT)

:Just curious...
:
:If EOF is 'int -1' (0xFFFFFFFF), then having is*( _unsigned_ int) will
:solve the problem:
:Programmer will need to explicitely cast values to unsigned int,
:resulting in 0xFF for char -1 and 0xFFFFFFFF for EOF.
:
:PS. I never have read the SUS, so don't shoot me dead... Just ignore
:if inappropriate :)

    It wouldn't work anyway, even if we could (and we can't since the
    type is specifically an 'int').  A char x = -1 will still wind up
    being 0xFFFFFFFF when cast to an unsigned int.

						-Matt



[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]