[all-commits] [llvm/llvm-project] ed0a14: [LLDB] Fix type formatting empty c-strings (#68924)

Walter Erquinigo via All-commits all-commits at lists.llvm.org
Fri Oct 13 11:14:36 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: ed0a14144ba980ceb29e86c9ca615b785e667dcf
      https://github.com/llvm/llvm-project/commit/ed0a14144ba980ceb29e86c9ca615b785e667dcf
  Author: Walter Erquinigo <a20012251 at gmail.com>
  Date:   2023-10-13 (Fri, 13 Oct 2023)

  Changed paths:
    M lldb/source/DataFormatters/TypeFormat.cpp
    M lldb/test/API/functionalities/data-formatter/builtin-formats/TestBuiltinFormats.py
    M lldb/test/API/functionalities/data-formatter/builtin-formats/main.cpp

  Log Message:
  -----------
  [LLDB] Fix type formatting empty c-strings (#68924)

The type formatter code is effectively considering empty strings as read
errors, which is wrong. The fix is very simple. We should rely on the
error object and stop checking the size. I also added a test.




More information about the All-commits mailing list