fixed getModuleSymbols
This commit is contained in:
@@ -325,7 +325,7 @@ static void getModuleSymbols(SgStatement* func, set<SgSymbol*>& symbs)
|
||||
}
|
||||
}
|
||||
|
||||
set<SgSymbol*> getModuleSymbols(SgStatement *func)
|
||||
const set<SgSymbol*>& getModuleSymbols(SgStatement *func)
|
||||
{
|
||||
auto it = symbolsForFunc.find(func->symbol()->identifier());
|
||||
if (it != symbolsForFunc.end())
|
||||
@@ -345,7 +345,7 @@ set<SgSymbol*> getModuleSymbols(SgStatement *func)
|
||||
}
|
||||
|
||||
symbolsForFunc[func->symbol()->identifier()] = symbs;
|
||||
return symbs;
|
||||
return symbolsForFunc[func->symbol()->identifier()];
|
||||
}
|
||||
|
||||
static void findSymbol(SgStatement* func, const string& varName, const string& locName,
|
||||
|
||||
Reference in New Issue
Block a user