Multiple ChoiceIntermediate 45s
Declared move ctor disables implicit copy
A class declares a move constructor `T(T&&)` but declares no copy constructor. What happens when code tries to copy the object?
Options
- 1The copy constructor is implicitly declared and works normally, copying each member in turn.
- 2The copy constructor is implicitly deleted; the copy fails to compile (or binds to nothing).
- 3The copy falls back to the move constructor, since the implicit copy was never generated.
- 4It compiles but calls the destructor twice, because the copy binds to the move constructor.
Think you can answer under pressure?
Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.