mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-10-19 11:02:59 +02:00
add helper method.
llvm-svn: 67989
This commit is contained in:
parent
2c6632d760
commit
696742399a
@ -78,6 +78,8 @@ namespace llvm {
|
|||||||
Val.setInt(1);
|
Val.setInt(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
bool isNull() const { return Val.getPointer() == 0; }
|
||||||
|
|
||||||
template<typename T>
|
template<typename T>
|
||||||
int is() const {
|
int is() const {
|
||||||
return Val.getInt() == ::llvm::getPointerUnionTypeNum<PT1, PT2>((T*)0);
|
return Val.getInt() == ::llvm::getPointerUnionTypeNum<PT1, PT2>((T*)0);
|
||||||
|
Loading…
Reference in New Issue
Block a user