mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-24 11:42:57 +01: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);
|
||||
}
|
||||
|
||||
bool isNull() const { return Val.getPointer() == 0; }
|
||||
|
||||
template<typename T>
|
||||
int is() const {
|
||||
return Val.getInt() == ::llvm::getPointerUnionTypeNum<PT1, PT2>((T*)0);
|
||||
|
Loading…
Reference in New Issue
Block a user