mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2025-02-19 17:31:55 +00:00
[flang] Accept "INFINITY" as real input
Both "INF" and "INFINITY" are standard. Differential Revision: https://reviews.llvm.org/D124401
This commit is contained in:
parent
c4caa90b15
commit
b8f5cf9d2c
@ -439,7 +439,13 @@ BigRadixFloatingPointNumber<PREC, LOG10RADIX>::ConvertToBinary(
|
||||
}
|
||||
if ((!limit || limit >= q + 3) && toupper(q[0]) == 'I' &&
|
||||
toupper(q[1]) == 'N' && toupper(q[2]) == 'F') {
|
||||
p = q + 3;
|
||||
if ((!limit || limit >= q + 8) && toupper(q[3]) == 'I' &&
|
||||
toupper(q[4]) == 'N' && toupper(q[5]) == 'I' &&
|
||||
toupper(q[6]) == 'T' && toupper(q[7]) == 'Y') {
|
||||
p = q + 8;
|
||||
} else {
|
||||
p = q + 3;
|
||||
}
|
||||
return {Real{Infinity()}};
|
||||
} else {
|
||||
// Invalid input
|
||||
|
Loading…
x
Reference in New Issue
Block a user