Parcourir la source

Merge topic 'win-fallthrough'

21541bb5 Use CM_FALLTHROUGH in Windows-specific code

Acked-by: Kitware Robot <[email protected]>
Merge-request: !1555
Brad King il y a 8 ans
Parent
commit
0b7822f49a

+ 2 - 0
Source/cmLocalVisualStudio7Generator.cxx

@@ -615,6 +615,7 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(
   switch (target->GetType()) {
     case cmStateEnums::OBJECT_LIBRARY:
       targetBuilds = false; // no manifest tool for object library
+      CM_FALLTHROUGH;
     case cmStateEnums::STATIC_LIBRARY:
       projectType = "typeStaticLibrary";
       configType = "4";
@@ -630,6 +631,7 @@ void cmLocalVisualStudio7Generator::WriteConfiguration(
     case cmStateEnums::UTILITY:
     case cmStateEnums::GLOBAL_TARGET:
       configType = "10";
+      CM_FALLTHROUGH;
     default:
       targetBuilds = false;
       break;

+ 1 - 0
Source/cmVisualStudio10TargetGenerator.cxx

@@ -52,6 +52,7 @@ static std::string cmVS10EscapeComment(std::string comment)
       case '>': /* no break */
       case '^':
         echoable += '^'; /* no break */
+        CM_FALLTHROUGH;
       default:
         echoable += *c;
         break;