summaryrefslogtreecommitdiffstats
path: root/Source/cmXCodeObject.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'Source/cmXCodeObject.cxx')
-rw-r--r--Source/cmXCodeObject.cxx12
1 files changed, 7 insertions, 5 deletions
diff --git a/Source/cmXCodeObject.cxx b/Source/cmXCodeObject.cxx
index c817980..ddd9669 100644
--- a/Source/cmXCodeObject.cxx
+++ b/Source/cmXCodeObject.cxx
@@ -4,6 +4,8 @@
#include <ostream>
+#include <cmext/string_view>
+
#include <CoreFoundation/CoreFoundation.h>
const char* cmXCodeObject::PBXTypeNames[] = {
@@ -91,13 +93,13 @@ void cmXCodeObject::Print(std::ostream& out)
out << this->Id;
this->PrintComment(out);
out << " = {";
- if (separator == "\n") {
+ if (separator == "\n"_s) {
out << separator;
}
cmXCodeObject::Indent(3 * indentFactor, out);
out << "isa = " << PBXTypeNames[this->IsA] << ";" << separator;
for (const auto& keyVal : this->ObjectAttributes) {
- if (keyVal.first == "isa") {
+ if (keyVal.first == "isa"_s) {
continue;
}
@@ -142,7 +144,7 @@ void cmXCodeObject::PrintAttribute(std::ostream& out, int level,
case ATTRIBUTE_GROUP: {
out << name << " = {";
- if (separator == "\n") {
+ if (separator == "\n"_s) {
out << separator;
}
for (const auto& keyVal : object->ObjectAttributes) {
@@ -156,7 +158,7 @@ void cmXCodeObject::PrintAttribute(std::ostream& out, int level,
case OBJECT_REF: {
cmXCodeObject::PrintString(out, name);
out << " = " << object->Object->Id;
- if (object->Object->HasComment() && name != "remoteGlobalIDString") {
+ if (object->Object->HasComment() && name != "remoteGlobalIDString"_s) {
object->Object->PrintComment(out);
}
out << ";" << separator;
@@ -180,7 +182,7 @@ void cmXCodeObject::PrintList(std::vector<cmXCodeObject*> const& objs,
{
cmXCodeObject::Indent(1, out);
out << "objects = {\n";
- for (auto obj : objs) {
+ for (auto* obj : objs) {
if (obj->TypeValue == OBJECT) {
obj->Print(out);
}