================
@@ -232,4 +232,19 @@ void RenderDiagnosticDetails(Stream &stream,
     }
 }
 
+bool TerminalSupportsUnicode() {
+  static std::optional<bool> result;
+  if (result)
+    return result.value();
+#ifndef _WIN32
+  if (const char *lang_var = std::getenv("LANG"))
+    result = std::string(lang_var).find("UTF-8");
+  else
+    result = false;
+#else
+  result = std::getenv("WT_SESSION") != nullptr;
+#endif
+  return result.value();
+}
----------------
JDevlieghere wrote:

Will this be correct for Xcode and DAP?

https://github.com/llvm/llvm-project/pull/167550
_______________________________________________
lldb-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to