This fixes the missing address space on this in the implicit move assignment operator.
The function called here is an abstraction around the lines that have been removed, and also sets the address space correctly.
This is copied from CopyConstructor, CopyAssignment and MoveConstructor, all of which use this new function, and now
MoveAssignment is has been aligned to use the same method.
I also added a new test file to check the output AST. If there's a better place for this test I will move it there.
Fixes: PR50259
Could you please relax these checks? The test fails with -triple i386-pc-win32 with errors like this:
ast-dump-implicit-members.clcpp:10:11: error: CHECK: expected string not found in input // CHECK: CXXConstructorDecl {{.*}} implicit used constexpr S 'void () __generic noexcept' ^ <stdin>:1:1: note: scanning from here Dumping __NSConstantString: ^ <stdin>:16:18: note: possible intended match here |-CXXConstructorDecl 0x10b6c718 <col:8> col:8 implicit used constexpr S 'void () __attribute__((thiscall)) __generic noexcept' inline default trivial ^