X86Subtarget.h: isTargetWindows() should tell whether he is targeting msvc.
authorNAKAMURA Takumi <geek4civic@gmail.com>
Sun, 30 Mar 2014 04:35:00 +0000 (04:35 +0000)
committerNAKAMURA Takumi <geek4civic@gmail.com>
Sun, 30 Mar 2014 04:35:00 +0000 (04:35 +0000)
FYI, !isWindowsGNUEnvironment() is insufficient. It missed cygwin.

FIXME: The name "isTargetWindows" should be fixed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@205124 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/X86/X86Subtarget.h

index d66d859505912c315a430b4dd72d59a9d229bf52..a8e97e610323807d4df12ebc224702bca7bacef3 100644 (file)
@@ -344,8 +344,7 @@ public:
   bool isTargetNaCl32() const { return isTargetNaCl() && !is64Bit(); }
   bool isTargetNaCl64() const { return isTargetNaCl() && is64Bit(); }
   bool isTargetWindows() const {
-    return TargetTriple.isOSWindows() &&
-           !TargetTriple.isWindowsGNUEnvironment();
+    return TargetTriple.isKnownWindowsMSVCEnvironment();
   }
   bool isTargetMingw() const { return TargetTriple.isWindowsGNUEnvironment(); }
   bool isTargetCygwin() const {