From 9468519f349bd87d2b8a9054d240db8c20e4078e Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Mon, 29 Apr 2002 18:25:33 +0000 Subject: [PATCH] Fix bug: test/Regression/Other/2002-04-29-NameBinding.ll llvm-svn: 2402 --- lib/AsmParser/llvmAsmParser.y | 13 +------------ 1 file changed, 1 insertion(+), 12 deletions(-) diff --git a/lib/AsmParser/llvmAsmParser.y b/lib/AsmParser/llvmAsmParser.y index ad5e57e04ae..1dcc25cf5eb 100644 --- a/lib/AsmParser/llvmAsmParser.y +++ b/lib/AsmParser/llvmAsmParser.y @@ -248,18 +248,7 @@ static const Type *getTypeVal(const ValID &D, bool DoNotImprovise = false) { static Value *lookupInSymbolTable(const Type *Ty, const string &Name) { SymbolTable *SymTab = inFunctionScope() ? CurMeth.CurrentFunction->getSymbolTable() : 0; - Value *N = SymTab ? SymTab->lookup(Ty, Name) : 0; - - if (N == 0) { - // Symbol table doesn't automatically chain yet... because the method - // hasn't been added to the module... - // - SymTab = CurModule.CurrentModule->getSymbolTable(); - if (SymTab) - N = SymTab->lookup(Ty, Name); - } - - return N; + return SymTab ? SymTab->lookup(Ty, Name) : 0; } // getValNonImprovising - Look up the value specified by the provided type and