================
@@ -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");
----------------
JDevlieghere wrote:

```suggestion
    result = llvm::StringRef(lang_var).find("UTF-8");
```

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