mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-27 04:18:42 +00:00
[TableGen] Make BitRecTy::baseClassOf return true when RHS is an IntRecTy.
Previously the code was accidentally checking if 'this' was an IntRecTy which it can't be since 'this' is a BitRecTy. Looking back at the history it appears it was intended to check RHS. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235477 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
1 parent
aee08e5bac
commit
459448abcc
1 file changed
+1
-1
@@ -133,7 +133,7 @@ Init *BitRecTy::convertValue(TypedInit *VI) {
|
||||
}
|
||||
|
||||
bool BitRecTy::baseClassOf(const RecTy *RHS) const{
|
||||
if(RecTy::baseClassOf(RHS) || getRecTyKind() == IntRecTyKind)
|
||||
if(RecTy::baseClassOf(RHS) || RHS->getRecTyKind() == IntRecTyKind)
|
||||
return true;
|
||||
if(const BitsRecTy *BitsTy = dyn_cast<BitsRecTy>(RHS))
|
||||
return BitsTy->getNumBits() == 1;
|
||||
|
||||
Reference in new issue
Block a user