[Development] QVector rvalue overloads for convenience functions?

Mandeep Sandhu mandeepsandhu.chd at gmail.com
Sat Mar 3 21:11:18 CET 2018


On Sat, Mar 3, 2018 at 11:46 AM, Christian Ehrlicher <Ch.Ehrlicher at gmx.de>
wrote:

> Hi,
>
> recently rvalue overloads for QVector::append(T), push_back(T) and others
> were added to QVector. But not for the convenience functions like
> operator<<(T) or operator +=(T). Is this an oversight


Why would an rvalue overload (by that I assume you mean move semantics)
apply to the += operator? You're not discarding the existing object, just
adding values from whats pointed to by the other  reference.

As for the << operator, it _might_ be an oversight, I'm not sure. Someone
else can chime in.

CMIIW.

-mandeep



> or by intention?
>
>
> Thx,
> Christian
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.qt-project.org/pipermail/development/attachments/20180303/e0016546/attachment.html>


More information about the Development mailing list