[all-commits] [llvm/llvm-project] b3718b: [llvm/Support] Fallback to $TERM if terminfo has n...

Med Ismail Bennani via All-commits all-commits at lists.llvm.org
Wed May 18 18:23:05 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b3718bc4672bcad45f155c6d2f9fce4ad409bb8e
      https://github.com/llvm/llvm-project/commit/b3718bc4672bcad45f155c6d2f9fce4ad409bb8e
  Author: Med Ismail Bennani <medismail.bennani at gmail.com>
  Date:   2022-05-18 (Wed, 18 May 2022)

  Changed paths:
    M llvm/lib/Support/Unix/Process.inc

  Log Message:
  -----------
  [llvm/Support] Fallback to $TERM if terminfo has no "colors" capability

It can happen on macOS that terminal doesn't report the "colors"
capability in the terminfo database, in which case `tigetnum` returns -1.

This doesn't mean however that the terminal doesn't supports color, it
just means that the capability is absent from the terminal description.

In that case, we should still fallback to the checking the $TERM
environment variable to see if it supports ANSI escapes codes.

Differential Revision: https://reviews.llvm.org/D125914

Signed-off-by: Med Ismail Bennani <medismail.bennani at gmail.com>


  Commit: d71d1a947bee1247e952f22c13ad3ed3d041e36a
      https://github.com/llvm/llvm-project/commit/d71d1a947bee1247e952f22c13ad3ed3d041e36a
  Author: Med Ismail Bennani <medismail.bennani at gmail.com>
  Date:   2022-05-18 (Wed, 18 May 2022)

  Changed paths:
    M lldb/packages/Python/lldbsuite/test/lldbpexpect.py

  Log Message:
  -----------
  [lldb/Test] Add `use_colors` argument to the PExpect.launch wrapper

This patch adds a new `use_colors` argument to the PExpect.launch
method.

As the name suggests, it allows the user to conditionally enable color
support in the debugger, which can be helpful to test functionalities that
rely on that, like progress reporting. It defaults to False.

Differential Revision: https://reviews.llvm.org/D125915

Signed-off-by: Med Ismail Bennani <medismail.bennani at gmail.com>


  Commit: 051a5ae99824fab879d9aade9d794e60ebc5c2e5
      https://github.com/llvm/llvm-project/commit/051a5ae99824fab879d9aade9d794e60ebc5c2e5
  Author: Med Ismail Bennani <medismail.bennani at gmail.com>
  Date:   2022-05-18 (Wed, 18 May 2022)

  Changed paths:
    M lldb/include/lldb/Core/DebuggerEvents.h
    M lldb/source/Core/Debugger.cpp
    A lldb/test/API/functionalities/progress_reporting/TestTrimmedProgressReporting.py

  Log Message:
  -----------
  [lldb/Core] Fix "sticky" long progress messages

When the terminal window is too small, lldb would wrap progress messages
accross multiple lines which would break the progress event handling
code that is supposed to clear the message once the progress is completed.

This causes the progress message to remain on the screen, sometimes partially,
which can be confusing for the user.

To fix this issue, this patch trims the progress message to the terminal
width taking into account the progress counter leading the message for
finite progress events and also the trailing `...`.

rdar://91993836

Differential Revision: https://reviews.llvm.org/D124785

Signed-off-by: Med Ismail Bennani <medismail.bennani at gmail.com>


  Commit: 3e54ea0cfa3074e36ebee11848e072785437a8b9
      https://github.com/llvm/llvm-project/commit/3e54ea0cfa3074e36ebee11848e072785437a8b9
  Author: Med Ismail Bennani <medismail.bennani at gmail.com>
  Date:   2022-05-18 (Wed, 18 May 2022)

  Changed paths:
    M lldb/examples/python/crashlog.py
    M lldb/examples/python/scripted_process/crashlog_scripted_process.py

  Log Message:
  -----------
  [lldb/crashlog] Fix line entries resolution in interactive mode

This patch subtracts 1 to the pc of any frame above frame 0 to get the
previous line entry and display the right line in the debugger.

This also rephrase some old comment from `48d157dd4`.

rdar://92686666

Differential Revision: https://reviews.llvm.org/D125928

Signed-off-by: Med Ismail Bennani <medismail.bennani at gmail.com>


Compare: https://github.com/llvm/llvm-project/compare/a5d618b393fe...3e54ea0cfa30


More information about the All-commits mailing list