This is an archive of the discontinued LLVM Phabricator instance.

[CodeGen] Add missing copy assignment operator
ClosedPublic

Authored by aganea on Nov 25 2022, 7:18 AM.

Details

Summary

When building on Windows with clang-cl ToT, before this patch I was seeing:

[2690/5505] Building CXX object lib/Target/ARM/CMakeFiles/LLVMARMCodeGen.dir/ARMISelLowering.cpp.obj
In file included from D:/git/llvm-project/llvm/lib/Target/ARM/ARMISelLowering.cpp:14:
In file included from D:/git/llvm-project/llvm/lib/Target/ARM/ARMISelLowering.h:23:
D:/git/llvm-project/llvm/include\llvm/CodeGen/SelectionDAGNodes.h(760,5): warning: definition of implicit copy assignment operator for 'use_iterator' is deprecated because it has a user-declared copy constructor [-Wdeprecated-copy]
    use_iterator(const use_iterator &I) = default;
    ^
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\include\xutility(1015,13): note: in implicit copy assignment operator for 'llvm::SDNode::use_iterator' first required here
        _It = _STD forward<_UIter>(_UIt);
            ^
C:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\include\xutility(5604,5): note: in instantiation of function template specialization 'std::_Seek_wrapped<llvm::SDNode::use_iterator, llvm::SDNode::use_iterator &>' requested here
    _Seek_wrapped(_First, _UFirst);
    ^
D:/git/llvm-project/llvm/include\llvm/ADT/STLExtras.h(1737,15): note: in instantiation of function template specialization 'std::find_if<llvm::SDNode::use_iterator, (lambda at D:/git/llvm-project/llvm/lib/Target/ARM/ARMISelLowering.cpp:15310:39)>' requested here
  return std::find_if(adl_begin(Range), adl_end(Range), P);
              ^
1 warning generated.

Diff Detail

Event Timeline

aganea created this revision.Nov 25 2022, 7:18 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 25 2022, 7:18 AM
aganea requested review of this revision.Nov 25 2022, 7:18 AM
Herald added a project: Restricted Project. · View Herald TranscriptNov 25 2022, 7:18 AM
kazu accepted this revision.Nov 25 2022, 9:06 AM

LGTM. Thanks!

This revision is now accepted and ready to land.Nov 25 2022, 9:06 AM

LGTM. Thanks!

Thanks for reviewing!

This revision was landed with ongoing or failed builds.Nov 26 2022, 7:41 AM
This revision was automatically updated to reflect the committed changes.