summaryrefslogtreecommitdiffstats
path: root/llvm/lib/TableGen
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@gmail.com>2015-04-22 02:09:42 +0000
committerCraig Topper <craig.topper@gmail.com>2015-04-22 02:09:42 +0000
commitf8344c60a69bfd9388bf0a5bdd13f504c6b7b53e (patch)
tree29ffc7151e042ce19e104aaad6400e0f78926671 /llvm/lib/TableGen
parent09118e07eefbe62abd12bf8ca519a1f69c40962f (diff)
downloadbcm5719-llvm-f8344c60a69bfd9388bf0a5bdd13f504c6b7b53e.tar.gz
bcm5719-llvm-f8344c60a69bfd9388bf0a5bdd13f504c6b7b53e.zip
[TableGen] Use cast instead of dyn_cast where result isn't checked before being dereferenced.
llvm-svn: 235463
Diffstat (limited to 'llvm/lib/TableGen')
-rw-r--r--llvm/lib/TableGen/Record.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/TableGen/Record.cpp b/llvm/lib/TableGen/Record.cpp
index 8a8f0ee3a08..3374432daa6 100644
--- a/llvm/lib/TableGen/Record.cpp
+++ b/llvm/lib/TableGen/Record.cpp
@@ -345,7 +345,7 @@ Init *DagRecTy::convertValue(BinOpInit *BO) {
}
RecordRecTy *RecordRecTy::get(Record *R) {
- return dyn_cast<RecordRecTy>(R->getDefInit()->getType());
+ return cast<RecordRecTy>(R->getDefInit()->getType());
}
std::string RecordRecTy::getAsString() const {
OpenPOWER on IntegriCloud