summaryrefslogtreecommitdiffstats
path: root/Source/cmQtAutoGenerator.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmQtAutoGenerator.cxx')
-rw-r--r--Source/cmQtAutoGenerator.cxx28
1 files changed, 13 insertions, 15 deletions
diff --git a/Source/cmQtAutoGenerator.cxx b/Source/cmQtAutoGenerator.cxx
index e2d7deb..af50c1d 100644
--- a/Source/cmQtAutoGenerator.cxx
+++ b/Source/cmQtAutoGenerator.cxx
@@ -43,8 +43,7 @@ std::string cmQtAutoGenerator::Logger::HeadLine(std::string const& title)
return head;
}
-void cmQtAutoGenerator::Logger::Info(GeneratorT genType,
- std::string const& message)
+void cmQtAutoGenerator::Logger::Info(GenT genType, std::string const& message)
{
std::string msg = GeneratorName(genType);
msg += ": ";
@@ -58,7 +57,7 @@ void cmQtAutoGenerator::Logger::Info(GeneratorT genType,
}
}
-void cmQtAutoGenerator::Logger::Warning(GeneratorT genType,
+void cmQtAutoGenerator::Logger::Warning(GenT genType,
std::string const& message)
{
std::string msg;
@@ -82,7 +81,7 @@ void cmQtAutoGenerator::Logger::Warning(GeneratorT genType,
}
}
-void cmQtAutoGenerator::Logger::WarningFile(GeneratorT genType,
+void cmQtAutoGenerator::Logger::WarningFile(GenT genType,
std::string const& filename,
std::string const& message)
{
@@ -94,8 +93,7 @@ void cmQtAutoGenerator::Logger::WarningFile(GeneratorT genType,
Warning(genType, msg);
}
-void cmQtAutoGenerator::Logger::Error(GeneratorT genType,
- std::string const& message)
+void cmQtAutoGenerator::Logger::Error(GenT genType, std::string const& message)
{
std::string msg;
msg += HeadLine(GeneratorName(genType) + " error");
@@ -111,7 +109,7 @@ void cmQtAutoGenerator::Logger::Error(GeneratorT genType,
}
}
-void cmQtAutoGenerator::Logger::ErrorFile(GeneratorT genType,
+void cmQtAutoGenerator::Logger::ErrorFile(GenT genType,
std::string const& filename,
std::string const& message)
{
@@ -124,7 +122,7 @@ void cmQtAutoGenerator::Logger::ErrorFile(GeneratorT genType,
}
void cmQtAutoGenerator::Logger::ErrorCommand(
- GeneratorT genType, std::string const& message,
+ GenT genType, std::string const& message,
std::vector<std::string> const& command, std::string const& output)
{
std::string msg;
@@ -297,7 +295,7 @@ bool cmQtAutoGenerator::FileSystem::FileRead(std::string& content,
return success;
}
-bool cmQtAutoGenerator::FileSystem::FileRead(GeneratorT genType,
+bool cmQtAutoGenerator::FileSystem::FileRead(GenT genType,
std::string& content,
std::string const& filename)
{
@@ -343,7 +341,7 @@ bool cmQtAutoGenerator::FileSystem::FileWrite(std::string const& filename,
return success;
}
-bool cmQtAutoGenerator::FileSystem::FileWrite(GeneratorT genType,
+bool cmQtAutoGenerator::FileSystem::FileWrite(GenT genType,
std::string const& filename,
std::string const& content)
{
@@ -387,7 +385,7 @@ bool cmQtAutoGenerator::FileSystem::MakeDirectory(std::string const& dirname)
return cmSystemTools::MakeDirectory(dirname);
}
-bool cmQtAutoGenerator::FileSystem::MakeDirectory(GeneratorT genType,
+bool cmQtAutoGenerator::FileSystem::MakeDirectory(GenT genType,
std::string const& dirname)
{
if (!MakeDirectory(dirname)) {
@@ -409,7 +407,7 @@ bool cmQtAutoGenerator::FileSystem::MakeParentDirectory(
}
bool cmQtAutoGenerator::FileSystem::MakeParentDirectory(
- GeneratorT genType, std::string const& filename)
+ GenT genType, std::string const& filename)
{
if (!MakeParentDirectory(filename)) {
Log()->ErrorFile(genType, filename, "Could not create parent directory");
@@ -447,7 +445,7 @@ void cmQtAutoGenerator::ReadOnlyProcessT::PipeT::UVAlloc(uv_handle_t* handle,
{
auto& pipe = *reinterpret_cast<PipeT*>(handle->data);
pipe.Buffer_.resize(suggestedSize);
- buf->base = &pipe.Buffer_.front();
+ buf->base = pipe.Buffer_.data();
buf->len = pipe.Buffer_.size();
}
@@ -555,11 +553,11 @@ bool cmQtAutoGenerator::ReadOnlyProcessT::start(
std::fill_n(reinterpret_cast<char*>(&UVOptions_), sizeof(UVOptions_), 0);
UVOptions_.exit_cb = &ReadOnlyProcessT::UVExit;
UVOptions_.file = CommandPtr_[0];
- UVOptions_.args = const_cast<char**>(&CommandPtr_.front());
+ UVOptions_.args = const_cast<char**>(CommandPtr_.data());
UVOptions_.cwd = Setup_.WorkingDirectory.c_str();
UVOptions_.flags = UV_PROCESS_WINDOWS_HIDE;
UVOptions_.stdio_count = static_cast<int>(UVOptionsStdIO_.size());
- UVOptions_.stdio = &UVOptionsStdIO_.front();
+ UVOptions_.stdio = UVOptionsStdIO_.data();
// -- Spawn process
if (UVProcess_.spawn(*uv_loop, UVOptions_, this) != 0) {