Merge topic 'fix-vs2015-warnings'
b138be07 cmVisualStudio10TargetGenerator: fix a narrowing warning 8d379cd7 cmCallVisualStudioMacro: fix a shadowing warning
This commit is contained in:
commit
c61efbd684
@ -63,12 +63,13 @@ static bool LogErrorsAsMessages;
|
|||||||
{ \
|
{ \
|
||||||
if (LogErrorsAsMessages) \
|
if (LogErrorsAsMessages) \
|
||||||
{ \
|
{ \
|
||||||
std::ostringstream oss; \
|
std::ostringstream _hresult_oss; \
|
||||||
oss.flags(std::ios::hex); \
|
_hresult_oss.flags(std::ios::hex); \
|
||||||
oss << context << " failed HRESULT, hr = 0x" << hr << std::endl; \
|
_hresult_oss << context << " failed HRESULT, hr = 0x" \
|
||||||
oss.flags(std::ios::dec); \
|
<< hr << std::endl; \
|
||||||
oss << __FILE__ << "(" << __LINE__ << ")"; \
|
_hresult_oss.flags(std::ios::dec); \
|
||||||
cmSystemTools::Message(oss.str().c_str()); \
|
_hresult_oss << __FILE__ << "(" << __LINE__ << ")"; \
|
||||||
|
cmSystemTools::Message(_hresult_oss.str().c_str()); \
|
||||||
} \
|
} \
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -307,7 +307,7 @@ void cmVisualStudio10TargetGenerator::Generate()
|
|||||||
this->BuildFileStream->SetCopyIfDifferent(true);
|
this->BuildFileStream->SetCopyIfDifferent(true);
|
||||||
|
|
||||||
// Write the encoding header into the file
|
// Write the encoding header into the file
|
||||||
char magic[] = {0xEF,0xBB, 0xBF};
|
char magic[] = {char(0xEF), char(0xBB), char(0xBF)};
|
||||||
this->BuildFileStream->write(magic, 3);
|
this->BuildFileStream->write(magic, 3);
|
||||||
|
|
||||||
//get the tools version to use
|
//get the tools version to use
|
||||||
@ -937,7 +937,7 @@ void cmVisualStudio10TargetGenerator::WriteGroups()
|
|||||||
path += ".vcxproj.filters";
|
path += ".vcxproj.filters";
|
||||||
cmGeneratedFileStream fout(path.c_str());
|
cmGeneratedFileStream fout(path.c_str());
|
||||||
fout.SetCopyIfDifferent(true);
|
fout.SetCopyIfDifferent(true);
|
||||||
char magic[] = {0xEF,0xBB, 0xBF};
|
char magic[] = {char(0xEF), char(0xBB), char(0xBF)};
|
||||||
fout.write(magic, 3);
|
fout.write(magic, 3);
|
||||||
cmGeneratedFileStream* save = this->BuildFileStream;
|
cmGeneratedFileStream* save = this->BuildFileStream;
|
||||||
this->BuildFileStream = & fout;
|
this->BuildFileStream = & fout;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user