[lldb] [llvm] [lldb][windows] use Windows APIs to print to the console (PR #149493)

Adrian Prantl via llvm-commits llvm-commits at lists.llvm.org
Mon Aug 4 09:03:19 PDT 2025


================
@@ -247,6 +248,26 @@ uint32_t File::GetPermissions(Status &error) const {
   return file_stats.st_mode & (S_IRWXU | S_IRWXG | S_IRWXO);
 }
 
+NativeFile::NativeFile() = default;
+
+NativeFile::NativeFile(FILE *fh, bool transfer_ownership)
+    : m_stream(fh), m_own_stream(transfer_ownership) {
+#ifdef _WIN32
----------------
adrian-prantl wrote:

Could you add a comment here explains why we do something special on Windows and (just once sentence) on why/how this works?

https://github.com/llvm/llvm-project/pull/149493


More information about the llvm-commits mailing list