From 4687ff6d6d2863cc95c8137543ecf9c39bc01723 Mon Sep 17 00:00:00 2001 From: Vincent Bénony Date: Wed, 6 Jan 2016 15:11:40 +0100 Subject: DEVTOOL: Cleanup --- devtools/create_project/xcode.cpp | 2 +- devtools/create_project/xcode.h | 9 +++++---- 2 files changed, 6 insertions(+), 5 deletions(-) (limited to 'devtools') diff --git a/devtools/create_project/xcode.cpp b/devtools/create_project/xcode.cpp index 5a433f1dd0..a4fbbf1cb9 100644 --- a/devtools/create_project/xcode.cpp +++ b/devtools/create_project/xcode.cpp @@ -1126,7 +1126,7 @@ std::string XcodeProvider::writeProperty(const std::string &variable, Property & if (settings.size() > 1 || (prop._flags & kSettingsSingleItem)) output += (flags & kSettingsSingleItem ? " " : "\t\t\t\t"); - output += writeSetting((*setting).first, (*setting).second); + output += writeSetting(setting->first, setting->second); // The combination of SettingsAsList, and kSettingsSingleItem should use "," and not ";" (i.e children // in PBXGroup, so we special case that case here. diff --git a/devtools/create_project/xcode.h b/devtools/create_project/xcode.h index 698b02e651..ab9be96eb1 100644 --- a/devtools/create_project/xcode.h +++ b/devtools/create_project/xcode.h @@ -65,7 +65,7 @@ private: std::string _sourceTree; FileProperty(std::string fileType = "", std::string name = "", std::string path = "", std::string source = "") - : _fileEncoding(""), _lastKnownFileType(fileType), _fileName(name), _filePath(path), _sourceTree(source) { + : _fileEncoding(""), _lastKnownFileType(fileType), _fileName(name), _filePath(path), _sourceTree(source) { } }; @@ -152,7 +152,7 @@ private: struct Object { public: std::string _id; // Unique identifier for this object - std::string _name; // Name (may not be unique - for ex. configuration entries) + std::string _name; // Name (may not be unique - for ex. configuration entries) std::string _refType; // Type of object this references (if any) std::string _comment; // Main comment (empty for no comment) @@ -210,6 +210,7 @@ private: assert(!_properties["isa"]._settings.empty()); SettingList::iterator it = _properties["isa"]._settings.begin(); + return it->first; } }; @@ -233,8 +234,8 @@ private: } Object *find(std::string id) { - for (std::vector::iterator it = objects.begin(); it != objects.end(); ++it) { - if ((*it)->id == id) { + for (std::vector::iterator it = _objects.begin(); it != _objects.end(); ++it) { + if ((*it)->_id == id) { return *it; } } -- cgit v1.2.3