From ec106aa0f053b6ea6563b0430b2298c869e0a776 Mon Sep 17 00:00:00 2001 From: Dwayne Boone Date: Wed, 8 Jul 2015 13:33:41 -0230 Subject: ICE-6514 Removed uneeded includes of DisableWarnings.h --- cpp/src/Slice/Preprocessor.cpp | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'cpp/src/Slice/Preprocessor.cpp') diff --git a/cpp/src/Slice/Preprocessor.cpp b/cpp/src/Slice/Preprocessor.cpp index e3764d747cf..300e92b988a 100644 --- a/cpp/src/Slice/Preprocessor.cpp +++ b/cpp/src/Slice/Preprocessor.cpp @@ -7,7 +7,6 @@ // // ********************************************************************** -#include #include #include #include @@ -123,7 +122,7 @@ Slice::Preprocessor::normalizeIncludePath(const string& path) result.replace(pos, 2, "/"); } - if(result == "/" || (result.size() == 3 && IceUtilInternal::isAlpha(result[0]) && result[1] == ':' && + if(result == "/" || (result.size() == 3 && IceUtilInternal::isAlpha(result[0]) && result[1] == ':' && result[2] == '/')) { return result; @@ -149,7 +148,7 @@ baseArgs(vector args, bool keepComments, const string& extraArgs, const } args.push_back("-e"); args.push_back("en_us.utf8"); - + // // Define version macros __ICE_VERSION__ is preferred. We keep // ICE_VERSION for backward compatibility with 3.5.0. @@ -161,7 +160,7 @@ baseArgs(vector args, bool keepComments, const string& extraArgs, const os << "-D" << version[i] << "=" << ICE_INT_VERSION; args.push_back(os.str()); } - + if(!extraArgs.empty()) { args.push_back(extraArgs); @@ -234,9 +233,9 @@ Slice::Preprocessor::preprocess(bool keepComments, const string& extraArgs) // We use an unique id as the tmp file name prefix to avoid // problems with this code being called concurrently from // several processes, otherwise there is a change that two - // process call _tempnam before any of them call fopen and + // process call _tempnam before any of them call fopen and // they will end up using the same tmp file. - // + // char* name = _tempnam(0, ("slice-" + IceUtil::generateUUID()).c_str()); if(name) { @@ -295,7 +294,7 @@ Slice::Preprocessor::printMakefileDependencies(ostream& out, Language lang, cons { return false; } - + string cppHeaderExt; string pyPrefix; if(lang == CPlusPlus) @@ -313,7 +312,7 @@ Slice::Preprocessor::printMakefileDependencies(ostream& out, Language lang, cons vector args = _args; args.push_back("-M"); args = baseArgs(args, false, extraArgs, _fileName); - + const char** argv = new const char*[args.size() + 1]; for(unsigned int i = 0; i < args.size(); ++i) { @@ -399,10 +398,10 @@ Slice::Preprocessor::printMakefileDependencies(ostream& out, Language lang, cons // // Process each dependency. // - + string sourceFile; vector dependencies; - + string::size_type end; while((end = unprocessed.find(".ice", pos)) != string::npos) { @@ -497,7 +496,7 @@ Slice::Preprocessor::printMakefileDependencies(ostream& out, Language lang, cons result += ","; } } - + string::size_type pos = 0; while((pos = result.find("\\", pos + 1)) != string::npos) { -- cgit v1.2.3