[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: Potential issue in kshareddatacache.cpp checkin revision 1193778
From:       Thomas =?iso-8859-15?q?L=FCbking?= <thomas.luebking () gmail ! com>
Date:       2010-12-04 12:01:33
Message-ID: 201012041301.33574.thomas.luebking () gmail ! com
[Download RAW message or body]

Am Saturday 04 December 2010 schrieb Thiago Macieira:
> 0u is ISO C standard.
Thanks, just worried because of the "cumbesome" C cast.

> Also, a literal integer is automatically converted to the right type if the
> size fits. So 0 is a valid unsigned integer, but 128 isn't a valid uchar.
Yes, but not for templates ;-)

uint a = 1;
uint b = qMax( a, 2 ); // -> gcc sulks - happens to me once ever again
uint b = qMax( a, 2u ); // noprob

Cheers,
Thomas
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic