forked from qt-creator/qt-creator
Don't use qSNaN()
signalling NaNs are generally undesirable as they with trigger a signal on any further arithmetics operation done to them. Change-Id: Icebae3d4eb22c8294b11da234a2ba5c7e31b9733 Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
This commit is contained in:
@@ -53,7 +53,7 @@ static inline int toDigit(char c)
|
||||
double integerFromString(const char *buf, int size, int radix)
|
||||
{
|
||||
if (size == 0)
|
||||
return qSNaN();
|
||||
return qQNaN();
|
||||
|
||||
double sign = 1.0;
|
||||
int i = 0;
|
||||
@@ -92,7 +92,7 @@ double integerFromString(const char *buf, int size, int radix)
|
||||
if (!qstrcmp(buf, "Infinity"))
|
||||
result = qInf();
|
||||
else
|
||||
result = qSNaN();
|
||||
result = qQNaN();
|
||||
} else {
|
||||
result = 0;
|
||||
double multiplier = 1;
|
||||
|
Reference in New Issue
Block a user