Advertising
- Untitled
- Tuesday, May 22nd, 2007 at 3:01:13am UTC
- diff -Nur gizmod-3.1/libH/Debug.hpp gizmod-3.1.new/libH/Debug.hpp
- --- gizmod-3.1/libH/Debug.hpp 2007-05-18 22:30:15.000000000 +0900
- +++ gizmod-3.1.new/libH/Debug.hpp 2007-05-22 11:59:01.882826776 +0900
- @@ -78,9 +78,10 @@
- inline friend const Debug& operator << (const Debug & dbg, const std::string & s);
- inline friend const Debug& operator << (const Debug & dbg, const char c);
- inline friend const Debug& operator << (const Debug & dbg, const int d);
- + inline friend const Debug& operator << (const Debug & dbg, const unsigned int d);
- inline friend const Debug& operator << (const Debug & dbg, const long l);
- inline friend const Debug& operator << (const Debug & dbg, const bool b);
- - inline friend const Debug& operator << (const Debug & dbg, const size_t d);
- + inline friend const Debug& operator << (const Debug & dbg, const unsigned long l);
- inline friend const Debug& operator << (const Debug & dbg, const double lf);
- inline friend const Debug& operator << (const Debug & dbg, std::ostream&(*f)(std::ostream&)); // for endl
- @@ -184,6 +185,23 @@
- }
- /**
- + * \brief Debug insertion operator for uint
- + */
- +inline const Debug& operator << (const Debug & dbg, const unsigned int d) {
- + if (Debug::testPrint(dbg)) {
- + std::cout << d;
- + if (Debug::mLogToFile) {
- + Debug::mLogFile.open(Debug::mLogPath.c_str(), std::ios::app);
- + if (Debug::mLogFile.is_open()) {
- + Debug::mLogFile << d;
- + Debug::mLogFile.close();
- + }
- + }
- + }
- + return dbg;
- +}
- +
- +/**
- * \brief Debug insertion operator for long
- */
- inline const Debug& operator << (const Debug & dbg, const long l) {
- @@ -218,15 +236,15 @@
- }
- /**
- - * \brief Debug insertion operator for size_t
- + * \brief Debug insertion operator for ulong
- */
- -inline const Debug& operator << (const Debug & dbg, const size_t i) {
- +inline const Debug& operator << (const Debug & dbg, const unsigned long l) {
- if (Debug::testPrint(dbg)) {
- - std::cout << i;
- + std::cout << l;
- if (Debug::mLogToFile) {
- Debug::mLogFile.open(Debug::mLogPath.c_str(), std::ios::app);
- if (Debug::mLogFile.is_open()) {
- - Debug::mLogFile << i;
- + Debug::mLogFile << l;
- Debug::mLogFile.close();
- }
- }
advertising
Update the Post
Either update this post and resubmit it with changes, or make a new post.
You may also comment on this post.
Please note that information posted here will not expire by default. If you do not want it to expire, please set the expiry time above. If it is set to expire, web search engines will not be allowed to index it prior to it expiring. Items that are not marked to expire will be indexable by search engines. Be careful with your passwords. All illegal activities will be reported and any information will be handed over to the authorities, so be good.