Skip to content

Commit

Permalink
[PExplicit] Correct counting unexplored choices
Browse files Browse the repository at this point in the history
  • Loading branch information
aman-goel committed May 6, 2024
1 parent c6fb1f8 commit 8d6ee90
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -444,7 +444,7 @@ private void setChildTask(Choice choice, int choiceNum, SearchTask parentTask, b
newTask.addPrefixChoice(schedule.getChoice(i));
}

newTask.addSuffixChoice(choice.transferChoice());
newTask.addSuffixChoice(choice);

if (!isExact) {
for (int i = choiceNum + 1; i < schedule.size(); i++) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,13 +49,12 @@ public void addPrefixChoice(Choice choice) {
}

public void addSuffixChoice(Choice choice) {
// TODO: check if we need copy here
suffixChoices.add(choice.transferChoice());
if (choice instanceof ScheduleChoice scheduleChoice) {
numUnexploredScheduleChoices += scheduleChoice.getUnexplored().size();
} else {
numUnexploredDataChoices += ((DataChoice) choice).getUnexplored().size();
}
suffixChoices.add(choice.transferChoice());
}

public List<Choice> getAllChoices() {
Expand Down

0 comments on commit 8d6ee90

Please sign in to comment.