[PATCH] ADT/Triple: Helper to determine if we are targeting the Windows CRT

David Majnemer david.majnemer at gmail.com
Tue Aug 20 23:12:28 PDT 2013


majnemer added you to the CC list for the revision "ADT/Triple: Helper to determine if we are targeting the Windows CRT".

Hi rnk, asl, chandlerc,

This support will be utilized in things like clang to help check printf
format specifiers that are only valid when using the VSCRT.

http://llvm-reviews.chandlerc.com/D1455

Files:
  include/llvm/ADT/Triple.h

Index: include/llvm/ADT/Triple.h
===================================================================
--- include/llvm/ADT/Triple.h
+++ include/llvm/ADT/Triple.h
@@ -318,6 +318,11 @@
     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();
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D1455.2.patch
Type: text/x-patch
Size: 567 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130820/e82423e0/attachment.bin>


More information about the llvm-commits mailing list