clang-tidy: fix `modernize-use-default-member-init` lints
parent
63453bf4ef
commit
f8a2926986
|
@ -241,15 +241,10 @@ protected:
|
|||
private:
|
||||
struct LongestSourcePath
|
||||
{
|
||||
LongestSourcePath()
|
||||
: Length(0)
|
||||
, Target(0)
|
||||
, SourceFile(0)
|
||||
{
|
||||
}
|
||||
size_t Length;
|
||||
cmGeneratorTarget* Target;
|
||||
cmSourceFile const* SourceFile;
|
||||
LongestSourcePath() {}
|
||||
size_t Length = 0;
|
||||
cmGeneratorTarget* Target = 0;
|
||||
cmSourceFile const* SourceFile = 0;
|
||||
std::string SourceRel;
|
||||
};
|
||||
LongestSourcePath LongestSource;
|
||||
|
|
|
@ -564,7 +564,6 @@ public:
|
|||
: LG(lg)
|
||||
, Config(config)
|
||||
, Stream(os)
|
||||
, First(true)
|
||||
{
|
||||
}
|
||||
void Start(const char* tool)
|
||||
|
@ -610,7 +609,7 @@ private:
|
|||
cmLocalVisualStudio7Generator* LG;
|
||||
std::string Config;
|
||||
std::ostream& Stream;
|
||||
bool First;
|
||||
bool First = true;
|
||||
};
|
||||
|
||||
void cmLocalVisualStudio7Generator::WriteConfiguration(
|
||||
|
|
|
@ -90,7 +90,6 @@ cmVSSetupAPIHelper::cmVSSetupAPIHelper(unsigned int version)
|
|||
, setupConfig(NULL)
|
||||
, setupConfig2(NULL)
|
||||
, setupHelper(NULL)
|
||||
, initializationFailure(false)
|
||||
{
|
||||
comInitialized = CoInitializeEx(NULL, 0);
|
||||
if (SUCCEEDED(comInitialized)) {
|
||||
|
|
|
@ -17,7 +17,7 @@ template <class T>
|
|||
class SmartCOMPtr
|
||||
{
|
||||
public:
|
||||
SmartCOMPtr() { ptr = NULL; }
|
||||
SmartCOMPtr() {}
|
||||
SmartCOMPtr(T* p)
|
||||
{
|
||||
ptr = p;
|
||||
|
@ -65,13 +65,13 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
T* ptr;
|
||||
T* ptr = NULL;
|
||||
};
|
||||
|
||||
class SmartBSTR
|
||||
{
|
||||
public:
|
||||
SmartBSTR() { str = NULL; }
|
||||
SmartBSTR() {}
|
||||
SmartBSTR(const SmartBSTR& src) = delete;
|
||||
SmartBSTR& operator=(const SmartBSTR& src) = delete;
|
||||
operator BSTR() const { return str; }
|
||||
|
@ -79,7 +79,7 @@ public:
|
|||
~SmartBSTR() throw() { ::SysFreeString(str); }
|
||||
|
||||
private:
|
||||
BSTR str;
|
||||
BSTR str = NULL;
|
||||
};
|
||||
|
||||
struct VSInstanceInfo
|
||||
|
@ -129,7 +129,7 @@ private:
|
|||
SmartCOMPtr<ISetupConfiguration2> setupConfig2;
|
||||
SmartCOMPtr<ISetupHelper> setupHelper;
|
||||
// used to indicate failure in Initialize(), so we don't have to call again
|
||||
bool initializationFailure;
|
||||
bool initializationFailure = false;
|
||||
// indicated if COM initialization is successful
|
||||
HRESULT comInitialized;
|
||||
// current best instance of VS selected
|
||||
|
|
|
@ -140,14 +140,13 @@ private:
|
|||
std::stack<FileState> Stack;
|
||||
std::string EndIgnoreTag;
|
||||
DataGroupSet RequestedData;
|
||||
size_t CurrentLine;
|
||||
size_t CurrentLine = 0;
|
||||
|
||||
void IgnoreUntilTag(const std::string& endTag);
|
||||
};
|
||||
|
||||
cmVisualStudioSlnParser::State::State(DataGroupSet requestedData)
|
||||
: RequestedData(requestedData)
|
||||
, CurrentLine(0)
|
||||
{
|
||||
if (this->RequestedData.test(DataGroupProjectDependenciesBit))
|
||||
this->RequestedData.set(DataGroupProjectsBit);
|
||||
|
@ -386,8 +385,6 @@ void cmVisualStudioSlnParser::State::IgnoreUntilTag(const std::string& endTag)
|
|||
}
|
||||
|
||||
cmVisualStudioSlnParser::ResultData::ResultData()
|
||||
: Result(ResultOK)
|
||||
, ResultLine(0)
|
||||
{
|
||||
}
|
||||
|
||||
|
|
|
@ -73,8 +73,8 @@ protected:
|
|||
|
||||
struct ResultData
|
||||
{
|
||||
ParseResult Result;
|
||||
size_t ResultLine;
|
||||
ParseResult Result = ResultOK;
|
||||
size_t ResultLine = 0;
|
||||
bool HadBOM;
|
||||
|
||||
ResultData();
|
||||
|
|
|
@ -18,7 +18,6 @@ class cmVisualStudioWCEPlatformParser : public cmXMLParser
|
|||
public:
|
||||
cmVisualStudioWCEPlatformParser(const char* name = NULL)
|
||||
: RequiredName(name)
|
||||
, FoundRequiredName(false)
|
||||
{
|
||||
}
|
||||
|
||||
|
@ -61,7 +60,7 @@ private:
|
|||
std::vector<std::string> AvailablePlatforms;
|
||||
|
||||
const char* RequiredName;
|
||||
bool FoundRequiredName;
|
||||
bool FoundRequiredName = false;
|
||||
std::string VcInstallDir;
|
||||
std::string VsInstallDir;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue