[PATCH] D75278: Use FileDescriptorIsDisplayed in place of direct call to isatty in support library

Yuanfang Chen via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Mar 6 19:50:37 PST 2020


ychen added inline comments.


================
Comment at: llvm/lib/Support/raw_ostream.cpp:795
   // the complexity.
-  if (S_ISCHR(statbuf.st_mode) && isatty(FD))
+  if (S_ISCHR(statbuf.st_mode) && sys::Process::FileDescriptorIsDisplayed(FD))
     return 0;
----------------
Why not just use `raw_fd_ostream::is_displayed()` ?


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D75278





More information about the llvm-commits mailing list