summaryrefslogtreecommitdiffstats
path: root/Source
diff options
context:
space:
mode:
authorBen Boeckel <ben.boeckel@kitware.com>2023-02-03 20:18:44 (GMT)
committerBen Boeckel <ben.boeckel@kitware.com>2023-02-06 18:41:00 (GMT)
commitaf08f9dc556393750a955149afef22bb90ddc063 (patch)
treed6313789b6dbba83fd4e8a7ee6ea052a3dafb54b /Source
parent52ca45e4855e028fc6d3eeda0584ca0f26dd3880 (diff)
downloadCMake-af08f9dc556393750a955149afef22bb90ddc063.zip
CMake-af08f9dc556393750a955149afef22bb90ddc063.tar.gz
CMake-af08f9dc556393750a955149afef22bb90ddc063.tar.bz2
cmComputeLinkInformation: use characters where possible
Diffstat (limited to 'Source')
-rw-r--r--Source/cmComputeLinkInformation.cxx16
1 files changed, 8 insertions, 8 deletions
diff --git a/Source/cmComputeLinkInformation.cxx b/Source/cmComputeLinkInformation.cxx
index 3a51710..ff688a4 100644
--- a/Source/cmComputeLinkInformation.cxx
+++ b/Source/cmComputeLinkInformation.cxx
@@ -1399,7 +1399,7 @@ void cmComputeLinkInformation::ComputeItemParserInfo()
reg = "^(";
for (std::string const& p : this->LinkPrefixes) {
reg += p;
- reg += "|";
+ reg += '|';
}
reg += ")([^/:]*)";
@@ -1478,14 +1478,14 @@ std::string cmComputeLinkInformation::CreateExtensionRegex(
}
// Finish the list.
- libext += ")";
+ libext += ')';
// Add an optional OpenBSD-style version or major.minor.version component.
if (this->OpenBSD || type == LinkShared) {
libext += "(\\.[0-9]+)*";
}
- libext += "$";
+ libext += '$';
return libext;
}
@@ -1860,7 +1860,7 @@ void cmComputeLinkInformation::AddFrameworkItem(LinkEntry const& entry)
if (!fwDescriptor) {
std::ostringstream e;
e << "Could not parse framework path \"" << item << "\" linked by target "
- << this->Target->GetName() << ".";
+ << this->Target->GetName() << '.';
cmSystemTools::Error(e.str());
return;
}
@@ -2055,7 +2055,7 @@ bool cmComputeLinkInformation::FinishLinkerSearchDirectories()
case cmPolicies::REQUIRED_IF_USED:
case cmPolicies::REQUIRED_ALWAYS: {
std::ostringstream e;
- e << cmPolicies::GetRequiredPolicyError(cmPolicies::CMP0003) << "\n";
+ e << cmPolicies::GetRequiredPolicyError(cmPolicies::CMP0003) << '\n';
this->PrintLinkPolicyDiagnosis(e);
this->CMakeInstance->IssueMessage(MessageType::FATAL_ERROR, e.str(),
this->Target->GetBacktrace());
@@ -2098,7 +2098,7 @@ void cmComputeLinkInformation::PrintLinkPolicyDiagnosis(std::ostream& os)
// output the current line and reset it. Note that the separator
// is either " " or ", " which is always 2 characters.
if (!line.empty() && (line.size() + i.size() + 2) > max_size) {
- os << line << "\n";
+ os << line << '\n';
sep = " ";
line.clear();
}
@@ -2108,7 +2108,7 @@ void cmComputeLinkInformation::PrintLinkPolicyDiagnosis(std::ostream& os)
sep = ", ";
}
if (!line.empty()) {
- os << line << "\n";
+ os << line << '\n';
}
}
@@ -2117,7 +2117,7 @@ void cmComputeLinkInformation::PrintLinkPolicyDiagnosis(std::ostream& os)
std::set<std::string> emitted;
for (std::string const& i : this->OldLinkDirItems) {
if (emitted.insert(cmSystemTools::GetFilenamePath(i)).second) {
- os << " " << i << "\n";
+ os << " " << i << '\n';
}
}