Make the ToHex() util function always available, instead of debug only on win/linux. Useful for tracing addresses in psp log files...

This commit is contained in:
wrenczes@gmail.com
2011-03-01 08:53:15 +00:00
parent 9308c743a5
commit 1c228aba7a

View File

@@ -11,19 +11,18 @@
#include <string> #include <string>
#include <sstream> #include <sstream>
#if defined (WIN32) || defined (LINUX)
#ifdef _DEBUG
using namespace std; using namespace std;
template <class T> template <class T>
std::string ToHex(T* pointer) std::string ToHex(T* pointer)
{ {
std::ostringstream stream; std::ostringstream stream;
stream << std::hex << showbase << setfill('0') << setw(8) << (int) pointer; stream << hex << showbase << setfill('0') << setw(8) << (int) pointer;
return stream.str(); return stream.str();
} }
#if defined (WIN32) || defined (LINUX)
#ifdef _DEBUG
#ifndef QT_CONFIG #ifndef QT_CONFIG
#define DebugTrace(inString) \ #define DebugTrace(inString) \