Move the hex digits out of _q_toHex
Avoids them being duplicated several times in QtCore Change-Id: Idee0168ed9d452a572ad46e2a14d2d4d3c7d2f7e Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>bb10
parent
8e5e9d7987
commit
5b4c0da9d0
|
|
@ -50,11 +50,11 @@
|
|||
#endif
|
||||
QT_BEGIN_NAMESPACE
|
||||
|
||||
static const char digits[] = "0123456789abcdef";
|
||||
|
||||
template <class Char, class Integral>
|
||||
void _q_toHex(Char *&dst, Integral value)
|
||||
{
|
||||
static const char digits[] = "0123456789abcdef";
|
||||
|
||||
value = qToBigEndian(value);
|
||||
|
||||
const char* p = reinterpret_cast<const char*>(&value);
|
||||
|
|
|
|||
Loading…
Reference in New Issue