From 76dd4e894184f1e25396cc9eb1fd5fb584aaf551 Mon Sep 17 00:00:00 2001 From: Devang Patel Date: Thu, 30 Jul 2009 18:46:29 +0000 Subject: Do not use getNamedValue() to lookup NamedMDNode. NamedMDNode is not a GlobalValue. Thanks Benjamin Kramer! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77619 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/VMCore/Module.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/VMCore/Module.cpp') diff --git a/lib/VMCore/Module.cpp b/lib/VMCore/Module.cpp index 87d4b05cf1..9e1622e93d 100644 --- a/lib/VMCore/Module.cpp +++ b/lib/VMCore/Module.cpp @@ -293,7 +293,7 @@ GlobalAlias *Module::getNamedAlias(const StringRef &Name) const { /// specified name. This method returns null if a MDNode with the specified /// name is not found. NamedMDNode *Module::getNamedMetadata(const StringRef &Name) const { - return dyn_cast_or_null(getNamedValue(Name)); + return dyn_cast_or_null(getValueSymbolTable().lookup(Name)); } //===----------------------------------------------------------------------===// -- cgit v1.2.3-18-g5258