Code gen case statement ranges.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42766 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/CodeGen/CodeGenFunction.h b/CodeGen/CodeGenFunction.h
index f804aaa..67806d5 100644
--- a/CodeGen/CodeGenFunction.h
+++ b/CodeGen/CodeGenFunction.h
@@ -240,10 +240,14 @@
};
llvm::SmallVector<BreakContinue, 8> BreakContinueStack;
- // SwitchInsn - This is used by EmitCaseStmt() and EmitDefaultStmt() to
- // populate switch instruction
+ /// SwitchInsn - This is used by EmitCaseStmt() and EmitDefaultStmt() to
+ /// populate switch instruction
llvm::SwitchInst *SwitchInsn;
+ /// CaseRangeBlock - This is used, while constructiong swtich instruction,
+ /// to hold "if" condition for case statement ranges.
+ llvm::BasicBlock *CaseRangeBlock;
+
public:
CodeGenFunction(CodeGenModule &cgm);
@@ -322,6 +326,7 @@
void EmitSwitchStmt(const SwitchStmt &S);
void EmitDefaultStmt(const DefaultStmt &S);
void EmitCaseStmt(const CaseStmt &S);
+ void EmitCaseStmtRange(const CaseStmt &S);
//===--------------------------------------------------------------------===//
// LValue Expression Emission