summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support/Triple.cpp
diff options
context:
space:
mode:
authorDaniel Dunbar <daniel@zuster.org>2011-04-19 23:34:12 +0000
committerDaniel Dunbar <daniel@zuster.org>2011-04-19 23:34:12 +0000
commit0854f347d29515195d2ee95b26275d639752c6ea (patch)
treed8439bce1eafdc79e4aee89a6ce769d7d8c49607 /llvm/lib/Support/Triple.cpp
parent3ac6711aec757817bed518af307ca68bc6008fc3 (diff)
downloadbcm5719-llvm-0854f347d29515195d2ee95b26275d639752c6ea.tar.gz
bcm5719-llvm-0854f347d29515195d2ee95b26275d639752c6ea.zip
ADT/Triple: Add support for Triple::MacOSX per feedback from Chris, will remove
Triple::OSX once Clang has moved. llvm-svn: 129833
Diffstat (limited to 'llvm/lib/Support/Triple.cpp')
-rw-r--r--llvm/lib/Support/Triple.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/llvm/lib/Support/Triple.cpp b/llvm/lib/Support/Triple.cpp
index 8281b483c95..38cb15a50e6 100644
--- a/llvm/lib/Support/Triple.cpp
+++ b/llvm/lib/Support/Triple.cpp
@@ -102,6 +102,7 @@ const char *Triple::getOSTypeName(OSType Kind) {
case IOS: return "ios";
case Linux: return "linux";
case Lv2: return "lv2";
+ case MacOSX: return "macosx";
case MinGW32: return "mingw32";
case NetBSD: return "netbsd";
case OSX: return "osx";
@@ -322,6 +323,8 @@ Triple::OSType Triple::ParseOS(StringRef OSName) {
return Linux;
else if (OSName.startswith("lv2"))
return Lv2;
+ else if (OSName.startswith("macosx"))
+ return MacOSX;
else if (OSName.startswith("mingw32"))
return MinGW32;
else if (OSName.startswith("netbsd"))
OpenPOWER on IntegriCloud