8 Commits

Author SHA1 Message Date
Charles Zablit
8515ddaa2b
[lldb] fix failing diagnostics test when Unicode is supported (#172038)
This patch fixes a test failure introduced by
https://github.com/llvm/llvm-project/pull/171832 due to a check which
was not properly updated.
2025-12-12 09:30:23 -08:00
Charles Zablit
7345233fb6
[lldb] improve the heuristics for checking if a terminal supports Unicode (#171832)
This patch improves the way lldb checks if the terminal it's opened in
(if any) supports Unicode or not.

On POSIX systems, we check if `LANG` contains `UTF-8`.

On Windows, we always return `true` since we use the `WriteToConsoleW`
api.

This is a relanding of https://github.com/llvm/llvm-project/pull/168603.

The tests failed because the bots support Unicode but the tests expect
ASCII. To avoid different outputs depending on the environment the tests
are running in, this patch always force ASCII in the tests.
2025-12-12 15:07:08 +00:00
Charles Zablit
0b522d9e8e
Revert "[lldb] fix failing tests due to CI diagnostics rendering (#171791) 2025-12-11 10:16:01 +00:00
Charles Zablit
871dabc8ea
[lldb] fix failing tests due to CI diagnostics rendering (#171685)
This patch fixes issues introduced by
https://github.com/llvm/llvm-project/pull/171491 when running tests in
CI.

The shell tests expect certain characters when matching diagnostics.
With https://github.com/llvm/llvm-project/pull/171491, those characters
can either be Unicode specific characters or their ASCII equivalent. The
tests were always expecting the ASCII version. This patch fixes this by
using a regex to match one or the other.
2025-12-10 23:08:01 +00:00
Vladislav Dzhidzhoev
20c4e95b9c
[lldb][test] Fix remote Shell tests failures on Windows host (#115716)
Since the remote Shell test execution feature was added, these tests
should now be disabled on Windows target instead of Windows host.

It should fix failures on
https://lab.llvm.org/staging/#/builders/197/builds/76.
2024-11-12 18:03:24 +01:00
Muhammad Omair Javaid
69f7758ddb Revert "[lldb] Fix command-expr-diagnostics.test for Windows (#112109)"
This reverts commit eca3206d29e7ce97dd6336deaa3da96be37f8277.

This broke LLDB Linux bot for no apparent reason. I ll post a more
suitable fix later. Disabled command-expr-diagnostics.test on
windows for now.
2024-10-16 06:08:13 +05:00
Muhammad Omair Javaid
eca3206d29 [lldb] Fix command-expr-diagnostics.test for Windows (#112109)
This adds a minor change to command-expr-diagnostics.test to make
it pass on windows. Clang produces PDB on windows by default which
was ignoring main symbol due to optimization. The problem is fixed
by adding -gdwarf to commandline, making sure dwarf debug info gets
generated on both Windows and Linux.
2024-10-16 05:33:27 +05:00
Adrian Prantl
9eddc8b9bf
[lldb] Expose structured command diagnostics via the SBAPI. (#112109)
This allows IDEs to render LLDB expression diagnostics to their liking
without relying on characterprecise ASCII art from LLDB. It is exposed
as a versioned SBStructuredData object, since it is expected that this
may need to be tweaked based on actual usage.
2024-10-14 16:29:26 -07:00