Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[flang][msvc] Avoid a reinterpret_cast
The call to the binary->decimal formatter in real.cpp was cheating by using a reinterpret_cast<> to extract its binary value. Use a more principled and portable approach by extending the API of evaluate::Integer<> to include ToUInt<>()/ToSInt<>() member function templates that do the "right" thing. Retain ToUInt64()/ToSInt64() for compatibility. Differential revision: https://reviews.llvm.org/D89435
- Loading branch information
Showing
2 changed files
with
23 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters