mirror of
https://github.com/Kitware/CMake.git
synced 2025-10-20 04:24:36 +08:00
clang-tidy: avoid copy
This commit is contained in:
@@ -236,7 +236,7 @@ public:
|
|||||||
cmFileMonitor::Callback cb)
|
cmFileMonitor::Callback cb)
|
||||||
: Parent(p)
|
: Parent(p)
|
||||||
, PathSegment(ps)
|
, PathSegment(ps)
|
||||||
, CbList({ cb })
|
, CbList({ std::move(cb) })
|
||||||
{
|
{
|
||||||
assert(p);
|
assert(p);
|
||||||
assert(!ps.empty());
|
assert(!ps.empty());
|
||||||
|
@@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
struct cmListFileParser
|
struct cmListFileParser
|
||||||
{
|
{
|
||||||
cmListFileParser(cmListFile* lf, cmListFileBacktrace lfbt,
|
cmListFileParser(cmListFile* lf, cmListFileBacktrace const& lfbt,
|
||||||
cmMessenger* messenger, const char* filename);
|
cmMessenger* messenger, const char* filename);
|
||||||
~cmListFileParser();
|
~cmListFileParser();
|
||||||
void IssueFileOpenError(std::string const& text) const;
|
void IssueFileOpenError(std::string const& text) const;
|
||||||
@@ -39,7 +39,8 @@ struct cmListFileParser
|
|||||||
} Separation;
|
} Separation;
|
||||||
};
|
};
|
||||||
|
|
||||||
cmListFileParser::cmListFileParser(cmListFile* lf, cmListFileBacktrace lfbt,
|
cmListFileParser::cmListFileParser(cmListFile* lf,
|
||||||
|
cmListFileBacktrace const& lfbt,
|
||||||
cmMessenger* messenger,
|
cmMessenger* messenger,
|
||||||
const char* filename)
|
const char* filename)
|
||||||
: ListFile(lf)
|
: ListFile(lf)
|
||||||
|
Reference in New Issue
Block a user