[PATCH] D69773: [APFloat] Extend converting from special strings
Matt Arsenault via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Jan 20 14:18:50 PST 2020
arsenm added a comment.
LGTM with nits
================
Comment at: llvm/lib/Support/APFloat.cpp:2647
+ // If we have a 's' (or 'S') prefix, then this is a Signaling NaN.
+ bool IsSignaling = tolower(str.front()) == 's';
+ if (IsSignaling) {
----------------
For only this, I think == 's' or =='S' would be clearer
================
Comment at: llvm/lib/Support/APFloat.cpp:2666
+ // Parentheses should be balanced (and not empty).
+ if (!(str.size() > 2 && str.back() == ')'))
+ return false;
----------------
demorgan this
================
Comment at: llvm/lib/Support/APFloat.cpp:2673
+ // Determine the payload number's radix.
+ unsigned Radix;
+ if (str[0] == '0') {
----------------
Initialize to 10 and remove the else case?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D69773/new/
https://reviews.llvm.org/D69773
More information about the llvm-commits
mailing list