[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Comparing pointers via cast to int?
From: Adriaan de Groot <groot () kde ! org>
Date: 2004-10-28 20:15:26
Message-ID: 200410282215.32359.groot () kde ! org
[Download RAW message or body]
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
For warnings-- type fixes, I was watching a base compile when this line of
konqueror (konq_mainwindow.cc:1010) generated a warning:
if ( senderFrame && viewFrame && (uint)viewFrame != (uint)senderFrame )
Now, senderFrame and viewFrame are both QObject *, and what's worse is that an
int isn't necessarily big enough to hold those pointers. Would either of
if ( senderFrame && viewFrame && viewFrame != senderFrame )
if ( senderFrame && viewFrame &&
(void *)viewFrame != (void *)senderFrame )
be acceptable?
- --
Don't worry, 't ain't no shame to be stupid - ol' mouse.
GPG: FEA2 A3FE Adriaan de Groot
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (FreeBSD)
iD8DBQFBgVNkdqzuAf6io/4RAuqrAJ9oH6QekHMLQeVSH1IkuO4InbMW8ACgklyD
V4BHXvsTzcbqs2dA1SsG/sw=
=/aGR
-----END PGP SIGNATURE-----
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic