From ec2375fb5116ccb1dd97e0be75f7a44cdc8c2bac Mon Sep 17 00:00:00 2001 From: Rafael Espindola Date: Thu, 25 Jul 2013 02:50:08 +0000 Subject: Make these methods const correct. Thanks to Nick Lewycky for noticing it. llvm-svn: 187098 --- llvm/lib/IR/Module.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'llvm/lib/IR/Module.cpp') diff --git a/llvm/lib/IR/Module.cpp b/llvm/lib/IR/Module.cpp index 3d3dc73..968b8f4 100644 --- a/llvm/lib/IR/Module.cpp +++ b/llvm/lib/IR/Module.cpp @@ -233,8 +233,7 @@ Function *Module::getFunction(StringRef Name) const { /// If AllowLocal is set to true, this function will return types that /// have an local. By default, these types are not returned. /// -GlobalVariable *Module::getGlobalVariable(StringRef Name, - bool AllowLocal) const { +GlobalVariable *Module::getGlobalVariable(StringRef Name, bool AllowLocal) { if (GlobalVariable *Result = dyn_cast_or_null(getNamedValue(Name))) if (AllowLocal || !Result->hasLocalLinkage()) -- cgit v1.1