1 Commits

Author SHA1 Message Date
Pavel Samolysov
81595e9178
[Clang][Sema] Add a test for move ctor calling for a base class. NFC (#97164)
When clang compiles the following expression:

```c++
  return A{B{"Move Ctor"}};
```
(where `B` is a base class for `A`), it adds a call to the move
constructor of `B`. When the code is changed to...

```c++
  return A{{"No Move Ctor"}};
```
... a move constructor is invoked neither for `A` nor for `B`.

The lit test demonstrates the difference in the generated AST.
2024-07-28 13:44:57 +03:00