[Development] Move assignment without move constructors

Marc Mutz marc.mutz at kdab.com
Wed May 25 22:33:11 CEST 2016


On Monday 23 May 2016 22:45:28 Thiago Macieira wrote:
> Em segunda-feira, 23 de maio de 2016, às 20:40:36 PDT, Giuseppe D'Angelo
> 
> escreveu:
> > Any takers for the task?
> 
> I've already added it for QDateTime:
> 	https://codereview.qt-project.org/159085
> 
> It's part of the short date time work.

I'd really prefer move special member functions to be inline, for performance 
reasons. If someone now goes in and adds them as out-of-line, we'll've killed 
inline move ctors until at least Qt 6.

Actually, I'd prefer copy ctors to be inline, too, because they're all just 
QAtomicInt::ref(), and nothing worth hidin, and the compiler has a much better 
idea of what's going on if it doesn't hit out-of-line functions all the time. 
But that's something for Qt 6.

Thanks,
Marc

-- 
Marc Mutz <marc.mutz at kdab.com> | Senior Software Engineer
KDAB (Deutschland) GmbH & Co.KG, a KDAB Group Company
Tel: +49-30-521325470
KDAB - Qt, C++ and OpenGL Experts



More information about the Development mailing list