docs: public static PvmExecutionImpl determinePropagatingExecutionOnEnd(PvmExecutionImpl propagatingExecution, Map<ScopeImpl, PvmExecutionImpl> activityExecutionMapping) {
      if (!propagatingExecution.isScope()) {
        // non-scope executions may end in the "wrong" flow scope
        return propagatingExecution;
      }
      else {
        // superfluous scope executions won't be contained in the activity-execution mapping
        if (activityExecutionMapping.values().contains(propagatingExecution)) {
          return propagatingExecution;
        }
        else {
          // skip one scope
          propagatingExecution.remove();
          PvmExecutionImpl parent = propagatingExecution.getParent();
          parent.setActivity(propagatingExecution.getActivity());
          return propagatingExecution.getParent();
        }
      }
    }