diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2017-01-04 22:19:42 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2017-01-04 22:19:42 +0000 |
| commit | 8e0f8b8c96c8b0cf053dbf78cba1d534f05c99a2 (patch) | |
| tree | 2173cb011a5acb1fa9d98fcd6a549fec31595377 /contrib/llvm/lib/Support/NativeFormatting.cpp | |
| parent | d8c03e73dcf4987b182e9ba75540b289daaffc06 (diff) | |
| parent | 0c75eea8f661a82866688fd1fc4465883c4dd7d5 (diff) | |
Notes
Diffstat (limited to 'contrib/llvm/lib/Support/NativeFormatting.cpp')
| -rw-r--r-- | contrib/llvm/lib/Support/NativeFormatting.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/contrib/llvm/lib/Support/NativeFormatting.cpp b/contrib/llvm/lib/Support/NativeFormatting.cpp index bb8689141098..b951a88a38db 100644 --- a/contrib/llvm/lib/Support/NativeFormatting.cpp +++ b/contrib/llvm/lib/Support/NativeFormatting.cpp @@ -239,10 +239,7 @@ void llvm::write_double(raw_ostream &S, double N, FloatStyle Style, N *= 100.0; char Buf[32]; - unsigned Len; - Len = format(Spec.c_str(), N).snprint(Buf, sizeof(Buf)); - if (Style == FloatStyle::Percent) - ++Len; + format(Spec.c_str(), N).snprint(Buf, sizeof(Buf)); S << Buf; if (Style == FloatStyle::Percent) S << '%'; |
