1 Commits

3 changed files with 7 additions and 7 deletions

View File

@@ -442,9 +442,9 @@ static void replaceComment(string &dir, const char *firstChar)
}
}
void removeDvmSpfDirectives(SgFile* file, bool removeDvm, bool removeSpf, bool toCommentDvm)
void removeDvmSpfDirectives(SgFile* file, bool removeDvm, bool removeSpf, bool toComment)
{
if (!removeDvm && !removeSpf && !toCommentDvm)
if (!removeDvm && !removeSpf)
printInternalError(convertFileName(__FILE__).c_str(), __LINE__);
vector<SgStatement*> toDel;
@@ -470,7 +470,7 @@ void removeDvmSpfDirectives(SgFile* file, bool removeDvm, bool removeSpf, bool t
break;
const int var = st->variant();
if (isDVM_stat(st) && (removeDvm || toCommentDvm) || isSPF_stat(st) && removeSpf)
if (isDVM_stat(st) && removeDvm || isSPF_stat(st) && removeSpf)
if (st->fileName() == currFile)
toDel.push_back(st);
@@ -480,7 +480,7 @@ void removeDvmSpfDirectives(SgFile* file, bool removeDvm, bool removeSpf, bool t
}
}
if (toCommentDvm)
if (toComment && removeDvm)
{
for (auto &elem : toDel)
{
@@ -500,7 +500,7 @@ void removeDvmSpfDirectives(SgFile* file, bool removeDvm, bool removeSpf, bool t
elem->deleteStmt();
}
}
else //removeSpf or removeDvm
else
{
for (auto &elem : toDel)
{

View File

@@ -310,7 +310,7 @@ static void getModuleSymbols(SgStatement* func, set<SgSymbol*>& symbs)
SgSymbol* s = func->symbol()->next();
while (s)
{
if (IS_BY_USE(s) && s->scope() && s->scope()->symbol()->identifier() == currScope)
if (IS_BY_USE(s) && s->scope()->symbol()->identifier() == currScope)
symbs.insert(s);
s = s->next();
}

View File

@@ -1,3 +1,3 @@
#pragma once
#define VERSION_SPF "2401"
#define VERSION_SPF "2399"