[PATCH] D81110: [Support] Move color handling from raw_fd_ostream to raw_ostream
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 3 15:29:30 PDT 2020
MaskRay added inline comments.
================
Comment at: llvm/lib/Support/raw_ostream.cpp:514
+ if (colorcode) {
+ size_t len = strlen(colorcode);
+ write(colorcode, len);
----------------
`len` can be inlined
================
Comment at: llvm/lib/Support/raw_ostream.cpp:528
+ if (colorcode) {
+ size_t len = strlen(colorcode);
+ write(colorcode, len);
----------------
`len` can be inlined
================
Comment at: llvm/lib/Support/raw_ostream.cpp:542
+ if (colorcode) {
+ size_t len = strlen(colorcode);
+ write(colorcode, len);
----------------
`len` can be inlined
================
Comment at: llvm/unittests/Support/raw_ostream_test.cpp:357
+ raw_string_ostream Sos(S);
+ Sos.changeColor(raw_ostream::YELLOW);
+ EXPECT_TRUE(Sos.str().empty());
----------------
Can we print a character and check the byte sequence? We can do the tests on non-Windows platforms.
Repository:
rLLDB LLDB
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D81110/new/
https://reviews.llvm.org/D81110
More information about the llvm-commits
mailing list