Commit f51974f3 authored by Sarah Grebing's avatar Sarah Grebing

Bugfix for label matcher

parent cbd58a54
Pipeline #17790 failed with stages
in 96 minutes and 14 seconds
......@@ -112,11 +112,14 @@ public class KeYMatcher implements MatcherApi<KeyData> {
resultsFromLabelMatch = new ArrayList<>();
//compile pattern
String cleanLabel = label.replaceAll(" ", "");
Pattern regexpForLabel = Pattern.compile(cleanLabel);
String cleanLabel2 = cleanLabel.replaceAll("\\(", "\\\\(");
cleanLabel = cleanLabel2.replaceAll("\\)", "\\\\)");
String branchLabel = currentState.getData().getBranchingLabel();
String cleanBranchLabel = branchLabel.replaceAll(" ", "");
Pattern regexpForLabel = Pattern.compile(cleanLabel);
Matcher branchLabelMatcher = regexpForLabel.matcher(cleanBranchLabel);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment