[libcxx-commits] [PATCH] D71214: [libc++] reduce <complex> parsing time

Antonio Sanchez via Phabricator via libcxx-commits libcxx-commits at lists.llvm.org
Fri Apr 24 10:15:55 PDT 2020


cantonios added inline comments.
Herald added a reviewer: libc++.


================
Comment at: libcxx/include/complex:1444
 {
-    basic_ostringstream<_CharT, _Traits> __s;
-    __s.flags(__os.flags());
----------------
nick wrote:
> ldionne wrote:
> > I'm thinking there must be a reason why it was written that way, but I can't think of any and your version indeed seems more straightforward.
> I tried to dig into history and the code is from initial commit, so I hoped I will get insights during the review.
It was written this way to respect properties like field width.  This now breaks fixed-width printing of complex numbers.

See https://reviews.llvm.org/D78816


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D71214/new/

https://reviews.llvm.org/D71214





More information about the libcxx-commits mailing list