This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Problem with unsigned long long on ultrasparc


On Thu, 20 Aug 1998, Brad Lucier wrote:

: > Two things, -1 is an int not a long long (although does GCC promote it
: > to a long long in this case?),
: 
: Yes, it does seem to promote it; I printed out the two values
: as unsigned long longs in order to check this.

IIRC, your test case used printf("%ull", ...) which is NOT printing "long
long".  It's printing "unsigned int" followed by two "l" characters.

If you want to print "unsigned long long", use "%llu".  For "long long",
"%lld".  "%qu" and "%qd" may also work, but I do not have Slowlaris handy to
test.  :)

-- 
-- Todd Vierling (Personal tv@pobox.com; Bus. todd_vierling@xn.xerox.com)



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]