summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorMichael Gottesman <mgottesman@apple.com>2013-01-30 22:38:19 +0000
committerMichael Gottesman <mgottesman@apple.com>2013-01-30 22:38:19 +0000
commit58d19a661dca4fd60c9c7921f61bafc87cb20470 (patch)
tree1103e909ab3e5d4693356a6b9ce641dc6d376c42 /llvm
parenta46db7728e4b90b46bd68008e2068825901fcfab (diff)
downloadbcm5719-llvm-58d19a661dca4fd60c9c7921f61bafc87cb20470.tar.gz
bcm5719-llvm-58d19a661dca4fd60c9c7921f61bafc87cb20470.zip
Encapsulate testing that we have an iOS Triple in Triple.h in the method isiOS
so we follow the convention that all other platforms follow by having an is* test method. llvm-svn: 173983
Diffstat (limited to 'llvm')
-rw-r--r--llvm/include/llvm/ADT/Triple.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/llvm/include/llvm/ADT/Triple.h b/llvm/include/llvm/ADT/Triple.h
index 7968a129cc0..e987ffc8de4 100644
--- a/llvm/include/llvm/ADT/Triple.h
+++ b/llvm/include/llvm/ADT/Triple.h
@@ -296,9 +296,14 @@ public:
return getOS() == Triple::Darwin || getOS() == Triple::MacOSX;
}
+ /// Is this an iOS triple.
+ bool isiOS() const {
+ return getOS() == Triple::IOS;
+ }
+
/// isOSDarwin - Is this a "Darwin" OS (OS X or iOS).
bool isOSDarwin() const {
- return isMacOSX() || getOS() == Triple::IOS;
+ return isMacOSX() || isiOS();
}
/// \brief Tests for either Cygwin or MinGW OS
OpenPOWER on IntegriCloud