summaryrefslogtreecommitdiffstats
path: root/src/widgets/doc/snippets/javastyle.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2024-04-18 09:09:48 +0200
committerMarc Mutz <marc.mutz@qt.io>2024-04-18 19:06:02 +0200
commita56461883830cecf281b1d6db5e7d6103154d3d9 (patch)
treee87352d503bb04b27a642db0c28073516d3820c2 /src/widgets/doc/snippets/javastyle.cpp
parent5b6c6dab632a32a09963453b08731e9e33334e9a (diff)
HttpTestServer: pass std::function by value and move into place
Virtually all callers of this function (will) pass rvalues, so take the std::function by value (reaping C++17 guaranteed copy elision) and std::move() into the member variable ("perfect sink"). Like for many owning types, moves are much cheaper than copies for std::function, because the external state is merely tranferred between objects, and not copied. Amends e560adef213301318dcc13d4db155624846e0420. Pick-to: 6.7 Change-Id: I269b54e51ba09ac595ac4e4f255209778819adad Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
Diffstat (limited to 'src/widgets/doc/snippets/javastyle.cpp')
0 files changed, 0 insertions, 0 deletions