On Apr 19, 2011, at 1:29 PM, John McCall wrote:
>> + // If the body of the case is just a 'break', try to not emit an empty
>> block.
>> + if (isa<BreakStmt>(S.getSubStmt())) {
>> + JumpDest Block = BreakContinueStack.back().BreakBlock;
>> +
>> + // Only do this optimization if there are no cleanups that need
>> emitting.
>> + if (isObviouslyBranchWithoutCleanups(Block)) {
>> + llvm::APSInt CaseVal = S.getLHS()->EvaluateAsInt(getContext());
>
> This is common between these two code paths and would be nice to hoist.
Ok, r129808
-Chris
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits