mirror of
https://github.com/Kitware/CMake.git
synced 2026-02-22 06:59:01 -06:00
clang-tidy: Use default member initialization
This commit is contained in:
@@ -33,11 +33,8 @@ struct cmCommandContext
|
||||
cmCommandName(std::string const& name) { *this = name; }
|
||||
cmCommandName& operator=(std::string const& name);
|
||||
} Name;
|
||||
long Line;
|
||||
cmCommandContext()
|
||||
: Line(0)
|
||||
{
|
||||
}
|
||||
long Line = 0;
|
||||
cmCommandContext() {}
|
||||
cmCommandContext(const char* name, int line)
|
||||
: Name(name)
|
||||
, Line(line)
|
||||
@@ -53,11 +50,7 @@ struct cmListFileArgument
|
||||
Quoted,
|
||||
Bracket
|
||||
};
|
||||
cmListFileArgument()
|
||||
: Delim(Unquoted)
|
||||
, Line(0)
|
||||
{
|
||||
}
|
||||
cmListFileArgument() {}
|
||||
cmListFileArgument(const std::string& v, Delimiter d, long line)
|
||||
: Value(v)
|
||||
, Delim(d)
|
||||
@@ -70,8 +63,8 @@ struct cmListFileArgument
|
||||
}
|
||||
bool operator!=(const cmListFileArgument& r) const { return !(*this == r); }
|
||||
std::string Value;
|
||||
Delimiter Delim;
|
||||
long Line;
|
||||
Delimiter Delim = Unquoted;
|
||||
long Line = 0;
|
||||
};
|
||||
|
||||
class cmListFileContext
|
||||
@@ -79,11 +72,8 @@ class cmListFileContext
|
||||
public:
|
||||
std::string Name;
|
||||
std::string FilePath;
|
||||
long Line;
|
||||
cmListFileContext()
|
||||
: Line(0)
|
||||
{
|
||||
}
|
||||
long Line = 0;
|
||||
cmListFileContext() {}
|
||||
|
||||
static cmListFileContext FromCommandContext(cmCommandContext const& lfcc,
|
||||
std::string const& fileName)
|
||||
|
||||
Reference in New Issue
Block a user