Message6073

Author florian
Recipients florian, gabi, jendrik, malte, salome, silvan
Date 2017-01-11.16:35:25
Content
I had a look at the file history. The "return" statement that causes the
non-deterministic behavior here originated in revision 630. Before that revision
the control flow was different and maybe this change was unintended. Here is the
simplified control flow before and after revision 630:

Before revision 630:
for (LandmarkNode *node : nodes) {
    if (!obedient_orders && node->is_true_in_goal()) {
        A;
    } else if (!node->is_true_in_initial_state()) {
        B;
    }
}

After revision 630:
for (LandmarkNode *node : nodes) {
    if (node->is_true_in_initial_state())
        return;

    if (!obedient_orders && node->is_true_in_goal()) {
        A;
    } else {
        B;
    }
}

Both versions are different from the fix in msg2496 (replacing return by
continue) for landmarks that are true in the initial state *and* the goal state.
For them, the code "A;" was executed in the old version but is not executed with
return or continue. I don't really understand what the code does, so I don't
know if the old code did the right thing, but maybe this difference is worth
looking at.
History
Date User Action Args
2017-01-11 16:35:25floriansetmessageid: <1484148925.82.0.422899929839.issue383@unibas.ch>
2017-01-11 16:35:25floriansetrecipients: + florian, malte, gabi, jendrik, silvan, salome
2017-01-11 16:35:25florianlinkissue383 messages
2017-01-11 16:35:25floriancreate