summaryrefslogtreecommitdiffstats
path: root/llvm
diff options
context:
space:
mode:
authorDavid Majnemer <david.majnemer@gmail.com>2013-08-21 21:53:33 +0000
committerDavid Majnemer <david.majnemer@gmail.com>2013-08-21 21:53:33 +0000
commitd6d1a9859e142f7b67b49087b9649754a6a6b5cf (patch)
treea1a4a6f90f10c531e9c6ba7705ffc532420dc5ce /llvm
parent317912f5d659e90c9903d4a959ad2d3c0c79dc0e (diff)
downloadbcm5719-llvm-d6d1a9859e142f7b67b49087b9649754a6a6b5cf.tar.gz
bcm5719-llvm-d6d1a9859e142f7b67b49087b9649754a6a6b5cf.zip
ADT/Triple: Helper to determine if we are targeting the Windows CRT
Summary: This support will be utilized in things like clang to help check printf format specifiers that are only valid when using the VSCRT. Reviewers: rnk, asl, chandlerc Reviewed By: chandlerc CC: llvm-commits Differential Revision: http://llvm-reviews.chandlerc.com/D1455 llvm-svn: 188935
Diffstat (limited to 'llvm')
-rw-r--r--llvm/include/llvm/ADT/Triple.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/llvm/include/llvm/ADT/Triple.h b/llvm/include/llvm/ADT/Triple.h
index 8d968e8fa3a..4b53ad2f689 100644
--- a/llvm/include/llvm/ADT/Triple.h
+++ b/llvm/include/llvm/ADT/Triple.h
@@ -318,6 +318,11 @@ public:
return getOS() == Triple::Cygwin || getOS() == Triple::MinGW32;
}
+ /// \brief Is this a "Windows" OS targeting a "MSVCRT.dll" environment.
+ bool isOSMSVCRT() const {
+ return getOS() == Triple::Win32 || getOS() == Triple::MinGW32;
+ }
+
/// isOSWindows - Is this a "Windows" OS.
bool isOSWindows() const {
return getOS() == Triple::Win32 || isOSCygMing();
OpenPOWER on IntegriCloud