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:
@@ -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) \
|
||||||
|
|||||||
Reference in New Issue
Block a user