Skip to content

Commit 31ccceb

Browse files
committed
[libc][NFC] Make explicit casts for gcc
1 parent 2e8fa86 commit 31ccceb

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

libc/src/__support/high_precision_decimal.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -299,7 +299,8 @@ class HighPrecisionDecimal {
299299
continue;
300300
}
301301
if (this->num_digits < MAX_NUM_DIGITS) {
302-
this->digits[this->num_digits] = *numString - '0';
302+
this->digits[this->num_digits] =
303+
static_cast<uint8_t>(*numString - '0');
303304
++this->num_digits;
304305
} else if (*numString != '0') {
305306
this->truncated = true;

0 commit comments

Comments
 (0)