long long support for kdDebug
Bernhard Rosenkraenzer
bero at arklinux.org
Fri Dec 26 17:53:20 GMT 2003
The attached (trivial) patch adds long long/unsigned long long support to
kdDebug if Qt >= 3.3 (qt-copy) is used.
It's fairly important because QFile::size() among others can return long
longs these days...
LLaP
bero
--
Ark Linux - Linux for the masses
http://www.arklinux.org/
Redistribution and processing of this message is subject to
http://www.arklinux.org/terms.php
-------------- next part --------------
--- kdelibs/kdecore/kdebug.h.64bit~ 2003-10-14 07:50:52.000000000 +0200
+++ kdelibs/kdecore/kdebug.h 2003-12-26 19:42:54.000000000 +0100
@@ -172,6 +172,28 @@
QString tmp; tmp.setNum(i); output += tmp;
return *this;
}
+#if QT_VERSION >= 0x030300
+ /**
+ * Prints the given value.
+ * @param i the long long to print
+ * @return this stream
+ */
+ kdbgstream &operator<<(long long i) {
+ if (!print) return *this;
+ QString tmp; tmp.setNum(i); output += tmp;
+ return *this;
+ }
+ /**
+ * Prints the given value.
+ * @param i the unsigned long long to print
+ * @return this stream
+ */
+ kdbgstream &operator<<(unsigned long long i) {
+ if (!print) return *this;
+ QString tmp; tmp.setNum(i); output += tmp;
+ return *this;
+ }
+#endif
/**
* Flushes the output.
*/
More information about the kde-core-devel
mailing list