This is an archive of the discontinued LLVM Phabricator instance.

Modify CXXMethodDecl::isMoveAssignmentOperator() to look through type sugar
ClosedPublic

Authored by shafik on Jul 12 2022, 1:59 PM.

Details

Summary

Currently CXXMethodDecl::isMoveAssignmentOperator() does not look though type sugar and so if the parameter is a type alias it will not be able to detect that the method is a move assignment operator. This PR fixes that and adds a set of tests that covers that we correctly detect special member functions when defaulting or deleting them.

This fixes: https://github.com/llvm/llvm-project/issues/56456

Diff Detail

Event Timeline

shafik created this revision.Jul 12 2022, 1:59 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 12 2022, 1:59 PM
shafik requested review of this revision.Jul 12 2022, 1:59 PM
aaron.ballman accepted this revision.Jul 13 2022, 6:09 AM

LGTM, that's a great catch! You should also add a release note for the fix (to the bug fixes section) before landing.

This revision is now accepted and ready to land.Jul 13 2022, 6:09 AM

Code changes LGTM! Thanks!

shafik updated this revision to Diff 444744.Jul 14 2022, 11:27 AM

Adding release notes.

Herald added a project: Restricted Project. · View Herald TranscriptJul 14 2022, 4:10 PM