summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Bitcode
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2011-07-07 05:29:18 +0000
committerChris Lattner <sabre@nondot.org>2011-07-07 05:29:18 +0000
commit54677c15f351d9caf35b88853d6bb54f055b27f7 (patch)
tree222197aa2f1d13d21eb90e0cb6eb96564e016e9f /llvm/lib/Bitcode
parentcdfcc2dee6655f84076f373ce74e8caf8e5cf556 (diff)
downloadbcm5719-llvm-54677c15f351d9caf35b88853d6bb54f055b27f7.tar.gz
bcm5719-llvm-54677c15f351d9caf35b88853d6bb54f055b27f7.zip
type can be null
llvm-svn: 134601
Diffstat (limited to 'llvm/lib/Bitcode')
-rw-r--r--llvm/lib/Bitcode/Reader/BitcodeReader.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Bitcode/Reader/BitcodeReader.h b/llvm/lib/Bitcode/Reader/BitcodeReader.h
index 1fa6f827b9c..14033b095c6 100644
--- a/llvm/lib/Bitcode/Reader/BitcodeReader.h
+++ b/llvm/lib/Bitcode/Reader/BitcodeReader.h
@@ -212,7 +212,7 @@ public:
private:
const Type *getTypeByID(unsigned ID, bool isTypeTable = false);
Value *getFnValueByID(unsigned ID, const Type *Ty) {
- if (Ty->isMetadataTy())
+ if (Ty && Ty->isMetadataTy())
return MDValueList.getValueFwdRef(ID);
return ValueList.getValueFwdRef(ID, Ty);
}
OpenPOWER on IntegriCloud