aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/Value.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2004-10-16 18:06:07 +0000
committerChris Lattner <sabre@nondot.org>2004-10-16 18:06:07 +0000
commit7eb8a523320d05d9318c957c9840cfbde3cf5b6d (patch)
tree8e25f8b71af44f3ea5123489edbd0a3c068a738f /include/llvm/Value.h
parent076b3f169379df5e8362dcb37403b14444d5dafb (diff)
downloadexternal_llvm-7eb8a523320d05d9318c957c9840cfbde3cf5b6d.zip
external_llvm-7eb8a523320d05d9318c957c9840cfbde3cf5b6d.tar.gz
external_llvm-7eb8a523320d05d9318c957c9840cfbde3cf5b6d.tar.bz2
Add new UndefValueVal type
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17038 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/Value.h')
-rw-r--r--include/llvm/Value.h10
1 files changed, 6 insertions, 4 deletions
diff --git a/include/llvm/Value.h b/include/llvm/Value.h
index 2aed4d2..884b265 100644
--- a/include/llvm/Value.h
+++ b/include/llvm/Value.h
@@ -126,6 +126,7 @@ public:
BasicBlockVal, // This is an instance of BasicBlock
FunctionVal, // This is an instance of Function
GlobalVariableVal, // This is an instance of GlobalVariable
+ UndefValueVal, // This is an instance of UndefValue
ConstantExprVal, // This is an instance of ConstantExpr
ConstantAggregateZeroVal, // This is an instance of ConstantAggregateNull
SimpleConstantVal, // This is some other type of Constant
@@ -189,11 +190,12 @@ void Use::set(Value *V) {
// the subtype header files to test to see if the value is a subclass...
//
template <> inline bool isa_impl<Constant, Value>(const Value &Val) {
- return Val.getValueType() == Value::ConstantExprVal ||
- Val.getValueType() == Value::SimpleConstantVal ||
- Val.getValueType() == Value::ConstantAggregateZeroVal ||
+ return Val.getValueType() == Value::SimpleConstantVal ||
Val.getValueType() == Value::FunctionVal ||
- Val.getValueType() == Value::GlobalVariableVal;
+ Val.getValueType() == Value::GlobalVariableVal ||
+ Val.getValueType() == Value::ConstantExprVal ||
+ Val.getValueType() == Value::ConstantAggregateZeroVal ||
+ Val.getValueType() == Value::UndefValueVal;
}
template <> inline bool isa_impl<Argument, Value>(const Value &Val) {
return Val.getValueType() == Value::ArgumentVal;