llvm.org GIT mirror llvm / 67cb2f6
Do not let 'ftostr' return a string that starts with spaces. This allows the AsmWriter to emit FP constants like 1.0 in normal exponential notation instead of hex notation. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19279 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 15 years ago
1 changed file(s) with 3 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
9999 static inline std::string ftostr(double V) {
100100 char Buffer[200];
101101 sprintf(Buffer, "%20.6e", V);
102 return Buffer;
102 char *B = Buffer;
103 while (*B == ' ') ++B;
104 return B;
103105 }
104106
105107 static inline std::string LowercaseString(const std::string &S) {