[all-commits] [llvm/llvm-project] 19141c: [lldb] Mark operator== const to avoid ambiguity in...

Samira Bazuzi via All-commits all-commits at lists.llvm.org
Wed Oct 4 09:04:27 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 19141c4172ea5a4979fa0419dcf712d3f0cadefc
      https://github.com/llvm/llvm-project/commit/19141c4172ea5a4979fa0419dcf712d3f0cadefc
  Author: Samira Bazuzi <bazuzi at users.noreply.github.com>
  Date:   2023-10-04 (Wed, 04 Oct 2023)

  Changed paths:
    M lldb/include/lldb/Utility/XcodeSDK.h
    M lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp
    M lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.h
    M lldb/source/Utility/XcodeSDK.cpp

  Log Message:
  -----------
  [lldb] Mark operator== const to avoid ambiguity in C++20. (#68224)

C++20 will automatically generate an operator== with reversed operand
order, which is ambiguous with the written operator== when one argument
is marked const and the other isn't.

These operators currently trigger -Wambiguous-reversed-operator at usage
sites lldb/source/Symbol/SymbolFileOnDemand.cpp:68 and
lldb/source/Plugins/DynamicLoader/Darwin-Kernel/DynamicLoaderDarwinKernel.cpp:1286.




More information about the All-commits mailing list