Fix VS2013 build of CGOpenMPRuntime.cpp
authorHans Wennborg <hans@hanshq.net>
Sat, 30 Jul 2016 00:41:37 +0000 (00:41 +0000)
committerHans Wennborg <hans@hanshq.net>
Sat, 30 Jul 2016 00:41:37 +0000 (00:41 +0000)
It seems the compiler was getting confused by the in-class initializers
in local struct MapInfo, so moving those to a default constructor
instead.

llvm-svn: 277256

clang/lib/CodeGen/CGOpenMPRuntime.cpp

index a54b596..b3ea687 100644 (file)
@@ -5456,9 +5456,13 @@ public:
         RPK_MemberReference,
       };
       OMPClauseMappableExprCommon::MappableExprComponentListRef Components;
-      OpenMPMapClauseKind MapType = OMPC_MAP_unknown;
-      OpenMPMapClauseKind MapTypeModifier = OMPC_MAP_unknown;
-      ReturnPointerKind ReturnDevicePointer = RPK_None;
+      OpenMPMapClauseKind MapType;
+      OpenMPMapClauseKind MapTypeModifier;
+      ReturnPointerKind ReturnDevicePointer;
+
+      MapInfo()
+          : MapType(OMPC_MAP_unknown), MapTypeModifier(OMPC_MAP_unknown),
+            ReturnDevicePointer(RPK_None) {}
       MapInfo(
           OMPClauseMappableExprCommon::MappableExprComponentListRef Components,
           OpenMPMapClauseKind MapType, OpenMPMapClauseKind MapTypeModifier,