aboutsummaryrefslogtreecommitdiffstats
path: root/include/llvm/ADT
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
commit79ef34d1802eeea48aa4e9346abecbf8ceb2e8eb (patch)
tree88037616ce3c9a3f8fc0dcb15573885cebd060a6 /include/llvm/ADT
parent296ca41b2d305f4aaf1d0562c7da90dc20cd9e14 (diff)
downloadexternal_llvm-79ef34d1802eeea48aa4e9346abecbf8ceb2e8eb.zip
external_llvm-79ef34d1802eeea48aa4e9346abecbf8ceb2e8eb.tar.gz
external_llvm-79ef34d1802eeea48aa4e9346abecbf8ceb2e8eb.tar.bz2
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 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@188935 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/ADT')
-rw-r--r--include/llvm/ADT/Triple.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/llvm/ADT/Triple.h b/include/llvm/ADT/Triple.h
index 8d968e8..4b53ad2 100644
--- a/include/llvm/ADT/Triple.h
+++ b/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();