[all-commits] [llvm/llvm-project] 12ae3c: [lldb] Assert that CommandResultObject error messa...

David Spickett via All-commits all-commits at lists.llvm.org
Mon Jun 21 02:45:07 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 12ae3cb7ba5399b99c02e8a73c681192259e188f
      https://github.com/llvm/llvm-project/commit/12ae3cb7ba5399b99c02e8a73c681192259e188f
  Author: David Spickett <david.spickett at linaro.org>
  Date:   2021-06-21 (Mon, 21 Jun 2021)

  Changed paths:
    M lldb/source/Interpreter/CommandReturnObject.cpp

  Log Message:
  -----------
  [lldb] Assert that CommandResultObject error messages are not empty

The intention is now that AppendError/SetError/AppendRawError only
be called with some message to show. This enforces that.

For SetError with a Status and a fallback string first assert
that the Status is a failure Status. Then it calls SetError(StringRef)
which checks the message is valid. (which could be the fallback
or the Status')

Reviewed By: dblaikie

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




More information about the All-commits mailing list