output body of folded case again.



git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148361 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CGStmt.cpp b/lib/CodeGen/CGStmt.cpp
index c7a8cf6..97755e3 100644
--- a/lib/CodeGen/CGStmt.cpp
+++ b/lib/CodeGen/CGStmt.cpp
@@ -883,8 +883,10 @@
   // when we've constant-folded the switch, are emitting the constant case,
   // and part of the constant case includes another case statement.  For 
   // instance: switch (4) { case 4: do { case 5: } while (1); }
-  if (!SwitchInsn)
+  if (!SwitchInsn) {
+    EmitStmt(S.getSubStmt());
     return;
+  }
 
   // Handle case ranges.
   if (S.getRHS()) {
diff --git a/test/CodeGenCXX/switch-case-folding-2.cpp b/test/CodeGenCXX/switch-case-folding-2.cpp
index e1e66cf..7c0283f 100644
--- a/test/CodeGenCXX/switch-case-folding-2.cpp
+++ b/test/CodeGenCXX/switch-case-folding-2.cpp
@@ -18,4 +18,4 @@
  return test(5);
 }
 
-// CHECK-NOT: call i32 (i8*, ...)* @printf(
+// CHECK: call i32 (i8*, ...)* @_Z6printfPKcz