[all-commits] [llvm/llvm-project] b0060c: [lldb] Make comparing RegisterInfo::[alt_]name's p...

Raphael Isemann via All-commits all-commits at lists.llvm.org
Wed Feb 19 04:20:03 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: b0060c3a7868ef026d95d0cf8a076791ef74f474
      https://github.com/llvm/llvm-project/commit/b0060c3a7868ef026d95d0cf8a076791ef74f474
  Author: Raphael Isemann <teemperor at gmail.com>
  Date:   2020-02-19 (Wed, 19 Feb 2020)

  Changed paths:
    M lldb/source/Plugins/Process/Utility/DynamicRegisterInfo.cpp
    M lldb/source/Target/ABI.cpp

  Log Message:
  -----------
  [lldb] Make comparing RegisterInfo::[alt_]name's pointer value less footy-shooty

Comparing those two `const char *` values relies on the assumption that both
strings were created by a ConstString. Let's check that assumption with an
assert as otherwise this code silently does nothing and that's not great.




More information about the All-commits mailing list