Preprocessor: Reduce variable scope

This commit is contained in:
Daniel Marjamäki 2012-12-27 17:00:59 +01:00
parent 0585588fc7
commit 57488db9da
1 changed files with 2 additions and 1 deletions

View File

@ -796,7 +796,6 @@ void Preprocessor::preprocessWhitespaces(std::string &processedFile)
void Preprocessor::preprocess(std::istream &srcCodeStream, std::string &processedFile, std::list<std::string> &resultConfigurations, const std::string &filename, const std::list<std::string> &includePaths)
{
std::map<std::string, std::string> defs;
std::string forcedIncludes;
if (file0.empty())
@ -882,6 +881,8 @@ void Preprocessor::preprocess(std::istream &srcCodeStream, std::string &processe
}
if (_settings && !_settings->userDefines.empty()) {
std::map<std::string, std::string> defs;
// TODO: break out this code. There is other similar code.
std::string::size_type pos1 = 0;
while (pos1 != std::string::npos) {