s/CGDebugInfo::getContext/CGDebugInfo::getContextDescriptor/g to avoid confusion.

llvm-svn: 94760
This commit is contained in:
Devang Patel 2010-01-28 23:15:27 +00:00
parent 128aa9d176
commit 7bfc596fcf
2 changed files with 8 additions and 7 deletions

View File

@ -49,9 +49,9 @@ void CGDebugInfo::setLocation(SourceLocation Loc) {
CurLoc = CGM.getContext().getSourceManager().getInstantiationLoc(Loc);
}
/// getContext - Get context info for the decl.
llvm::DIDescriptor CGDebugInfo::getContext(const VarDecl *Decl,
llvm::DIDescriptor &CompileUnit) {
/// getContextDescriptor - Get context info for the decl.
llvm::DIDescriptor CGDebugInfo::getContextDescriptor(const VarDecl *Decl,
llvm::DIDescriptor &CompileUnit) {
if (Decl->isFileVarDecl())
return CompileUnit;
if (Decl->getDeclContext()->isFunctionOrMethod()) {
@ -1770,8 +1770,8 @@ void CGDebugInfo::EmitGlobalVariable(llvm::GlobalVariable *Var,
ArrayType::Normal, 0);
}
llvm::StringRef DeclName = Decl->getName();
DebugFactory.CreateGlobalVariable(getContext(Decl, Unit), DeclName, DeclName,
llvm::StringRef(), Unit, LineNo,
DebugFactory.CreateGlobalVariable(getContextDescriptor(Decl, Unit), DeclName,
DeclName, llvm::StringRef(), Unit, LineNo,
getOrCreateType(T, Unit),
Var->hasInternalLinkage(),
true/*definition*/, Var);

View File

@ -171,8 +171,9 @@ private:
void EmitDeclare(const BlockDeclRefExpr *BDRE, unsigned Tag, llvm::Value *AI,
CGBuilderTy &Builder, CodeGenFunction *CGF);
/// getContext - Get context info for the decl.
llvm::DIDescriptor getContext(const VarDecl *Decl,llvm::DIDescriptor &CU);
/// getContextDescriptor - Get context info for the decl.
llvm::DIDescriptor getContextDescriptor(const VarDecl *Decl,
llvm::DIDescriptor &CU);
/// getOrCreateCompileUnit - Get the compile unit from the cache or create a
/// new one if necessary.