mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-11-05 13:09:10 +00:00
Add another check
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12525 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
e83593b2d3
commit
944cfafe76
@ -493,6 +493,11 @@ void Verifier::visitInstruction(Instruction &I) {
|
||||
Assert1(I.getType() != Type::VoidTy || !I.hasName(),
|
||||
"Instruction has a name, but provides a void value!", &I);
|
||||
|
||||
// Check that the return value of the instruction is either void or a legal
|
||||
// value type.
|
||||
Assert1(I.getType() == Type::VoidTy || I.getType()->isFirstClassType(),
|
||||
"Instruction returns a non-scalar type!", &I);
|
||||
|
||||
// Check that all uses of the instruction, if they are instructions
|
||||
// themselves, actually have parent basic blocks. If the use is not an
|
||||
// instruction, it is an error!
|
||||
|
Loading…
Reference in New Issue
Block a user