summaryrefslogtreecommitdiff
path: root/src/main/java/ftbsc
diff options
context:
space:
mode:
author zaaarf <zaaarf@proton.me>2023-02-09 00:04:46 +0100
committer zaaarf <zaaarf@proton.me>2023-02-09 00:04:46 +0100
commit81eb9b17b76c0240eb34557fd5c1221d15c2a30a (patch)
tree56e82fe197fde88b9c5706b186f875a239cec427 /src/main/java/ftbsc
parent016846f92eab3a85f6481a4d517aef26e692355c (diff)
parentcf11af60d79187cf116e1ae99ec2ae1e9e702fda (diff)
Merge remote-tracking branch 'origin/dev' into dev
Diffstat (limited to 'src/main/java/ftbsc')
-rw-r--r--src/main/java/ftbsc/lll/tools/PatternMatcher.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/main/java/ftbsc/lll/tools/PatternMatcher.java b/src/main/java/ftbsc/lll/tools/PatternMatcher.java
index 0d71125..5719872 100644
--- a/src/main/java/ftbsc/lll/tools/PatternMatcher.java
+++ b/src/main/java/ftbsc/lll/tools/PatternMatcher.java
@@ -85,13 +85,13 @@ public class PatternMatcher {
if(ignoreLabels && cur.getType() == AbstractInsnNode.LABEL) continue;
if(ignoreFrames && cur.getType() == AbstractInsnNode.FRAME) continue;
if(ignoreLineNumbers && cur.getType() == AbstractInsnNode.LINE) continue;
- if(predicates.get(match).test(cur)) {
+ if(match == predicates.size()) {
+ last = cur.getPrevious(); //it was actually the preiovus run in this case
+ break;
+ } else if (predicates.get(match).test(cur)) {
match++;
if(first == null)
first = cur;
- } else if(match == predicates.size()) {
- last = cur.getPrevious(); //it was actually the preiovus run in this case
- break;
} else break;
}
if(first != null && last != null) {