mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2026-04-24 13:18:17 +00:00
Introduce isOpaqueTy and use it rather than isa<OpaqueType>. Also, move some
methods to try to have the type predicates be more logically positioned. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96349 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -45,11 +45,11 @@ Value::Value(const Type *ty, unsigned scid)
|
||||
UseList(0), Name(0) {
|
||||
if (isa<CallInst>(this) || isa<InvokeInst>(this))
|
||||
assert((VTy->isFirstClassType() || VTy->isVoidTy() ||
|
||||
isa<OpaqueType>(ty) || VTy->isStructTy()) &&
|
||||
ty->isOpaqueTy() || VTy->isStructTy()) &&
|
||||
"invalid CallInst type!");
|
||||
else if (!isa<Constant>(this) && !isa<BasicBlock>(this))
|
||||
assert((VTy->isFirstClassType() || VTy->isVoidTy() ||
|
||||
isa<OpaqueType>(ty)) &&
|
||||
ty->isOpaqueTy()) &&
|
||||
"Cannot create non-first-class values except for constants!");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user