Micro optimizations
ClosedPublic

Authored by aacid on Oct 13 2019, 4:34 PM.

Details

Summary

Add some const & for things that return const & so there's no need to make a copy
Add a std::move for a thing that we pass by copy and it's just saved in another variable

Diff Detail

Repository
R31 Breeze
Branch
master
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 17654
Build 17672: arc lint + arc unit
aacid created this revision.Oct 13 2019, 4:34 PM
Restricted Application added a project: Plasma. · View Herald TranscriptOct 13 2019, 4:34 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
aacid requested review of this revision.Oct 13 2019, 4:34 PM
zzag accepted this revision.Oct 14 2019, 8:31 AM
zzag added a subscriber: zzag.

Add some const & for things that return const & so there's no need to make a copy

For what it's worth, copy elision is guaranteed starting from C++17. \o/

This revision is now accepted and ready to land.Oct 14 2019, 8:31 AM
aacid closed this revision.Oct 14 2019, 6:56 PM