Enable -Wimplicit-fallthrough.
Falling through switch cases on a clang build must now annotate the fallthrough
with the FALLTHROUGH_INTENDED macro.
Bug: 17731372
Change-Id: I836451cd5f96b01d1ababdbf9eef677fe8fa8324
diff --git a/compiler/dex/local_value_numbering.cc b/compiler/dex/local_value_numbering.cc
index e411164..eb98916 100644
--- a/compiler/dex/local_value_numbering.cc
+++ b/compiler/dex/local_value_numbering.cc
@@ -1460,7 +1460,7 @@
uint16_t reg = GetOperandValue(mir->ssa_rep->uses[0]);
HandleNullCheck(mir, reg);
}
- // Intentional fall-through.
+ FALLTHROUGH_INTENDED;
case Instruction::INVOKE_STATIC:
case Instruction::INVOKE_STATIC_RANGE:
// Make ref args aliasing.
@@ -1583,7 +1583,7 @@
uint16_t reg = GetOperandValue(mir->ssa_rep->uses[0]);
HandleNullCheck(mir, reg);
}
- // Intentional fall-through.
+ FALLTHROUGH_INTENDED;
case Instruction::NEG_INT:
case Instruction::NOT_INT:
case Instruction::NEG_FLOAT:
@@ -1610,7 +1610,6 @@
}
break;
-
case Instruction::DOUBLE_TO_LONG:
case Instruction::LONG_TO_DOUBLE:
case Instruction::NEG_LONG:
@@ -1782,7 +1781,7 @@
case Instruction::APUT_OBJECT:
HandlePutObject(mir);
- // Intentional fall-through.
+ FALLTHROUGH_INTENDED;
case Instruction::APUT:
case Instruction::APUT_WIDE:
case Instruction::APUT_BYTE:
@@ -1804,7 +1803,7 @@
case Instruction::IPUT_OBJECT:
HandlePutObject(mir);
- // Intentional fall-through.
+ FALLTHROUGH_INTENDED;
case Instruction::IPUT:
case Instruction::IPUT_WIDE:
case Instruction::IPUT_BOOLEAN:
@@ -1826,7 +1825,7 @@
case Instruction::SPUT_OBJECT:
HandlePutObject(mir);
- // Intentional fall-through.
+ FALLTHROUGH_INTENDED;
case Instruction::SPUT:
case Instruction::SPUT_WIDE:
case Instruction::SPUT_BOOLEAN: