Fix 'signed/unsigned comparison' warning in wchar mode
Only happens on GCC 3.4 for some reason.
This commit is contained in:
parent
fd605bc9a7
commit
cf8cfb30ce
1 changed files with 1 additions and 1 deletions
|
@ -4395,7 +4395,7 @@ PUGI__NS_BEGIN
|
|||
PUGI__STATIC_ASSERT(sizeof(U) == 8 || sizeof(U) == 4 || sizeof(U) == 2);
|
||||
|
||||
const size_t max_digits10 = sizeof(U) == 8 ? 20 : sizeof(U) == 4 ? 10 : 5;
|
||||
const char max_lead = sizeof(U) == 8 ? '1' : sizeof(U) == 4 ? '4' : '6';
|
||||
const char_t max_lead = sizeof(U) == 8 ? '1' : sizeof(U) == 4 ? '4' : '6';
|
||||
const size_t high_bit = sizeof(U) * 8 - 1;
|
||||
|
||||
overflow = digits >= max_digits10 && !(digits == max_digits10 && (*start < max_lead || (*start == max_lead && result >> high_bit)));
|
||||
|
|
Loading…
Add table
Reference in a new issue