mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-22 06:45:37 +08:00
Fixed clazy warnings: pass large objects by reference to const.
This commit is contained in:
@@ -171,7 +171,7 @@ namespace BlackCoreTest
|
||||
mutable ConnectGuard m_guard;
|
||||
|
||||
mutable std::function<void(const ExpectUnit *)> m_onDone;
|
||||
void onDone(std::function<void(const ExpectUnit *)> callback) const { m_onDone = callback; }
|
||||
void onDone(const std::function<void(const ExpectUnit *)> &callback) const { m_onDone = callback; }
|
||||
|
||||
// Helper traits class. Given T is a pointer-to-member-of-U, ClassOf<T>::type is U.
|
||||
template <class T> struct ClassOf;
|
||||
|
||||
Reference in New Issue
Block a user