aboutsummaryrefslogtreecommitdiff
path: root/org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java
diff options
context:
space:
mode:
Diffstat (limited to 'org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java')
-rw-r--r--org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java b/org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java
index 51de3bf6..37c3ac3b 100644
--- a/org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java
+++ b/org.jacoco.core/src/org/jacoco/core/internal/analysis/filter/KotlinWhenFilter.java
@@ -38,8 +38,7 @@ public final class KotlinWhenFilter implements IFilter {
public void filter(final MethodNode methodNode,
final IFilterContext context, final IFilterOutput output) {
final Matcher matcher = new Matcher();
- for (AbstractInsnNode i = methodNode.instructions
- .getFirst(); i != null; i = i.getNext()) {
+ for (final AbstractInsnNode i : methodNode.instructions) {
matcher.match(i, output);
}
}
@@ -93,7 +92,7 @@ public final class KotlinWhenFilter implements IFilter {
labels = ((TableSwitchInsnNode) switchNode).labels;
}
final Set<AbstractInsnNode> newTargets = new HashSet<AbstractInsnNode>();
- for (LabelNode label : labels) {
+ for (final LabelNode label : labels) {
newTargets.add(AbstractMatcher.skipNonOpcodes(label));
}
output.replaceBranches(switchNode, newTargets);