aaron.ballman added a comment.

This patch is missing test coverage.



================
Comment at: clang-tidy/ClangTidy.cpp:99-103
+    if (Context.getOptions().ShowColor.hasValue()) {
+      DiagOpts->ShowColors = Context.getOptions().ShowColor.getValue();
+    } else {
+      DiagOpts->ShowColors = llvm::sys::Process::StandardOutHasColors();
+    }
----------------
I think this can be simplified to:
```
DiagOpts->ShowColors = 
Context.getOptions().ShowColor.getValueOr(llvm::sys::Process::StandardOutHasColors());
```


================
Comment at: clang-tidy/tool/ClangTidyMain.cpp:150-152
+Show color diagnostics. If not specified,
+defaults to on when a color-capable terminal
+is detected.)"),
----------------
I think this raw string can be reflowed a bit?

Instead of "defaults to on", how about "Defaults to true when a color-capable 
terminal is detected."?


Repository:
  rL LLVM

https://reviews.llvm.org/D41720



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to