This also fixes goal, but requires small change in swipl (on Monday I will see...)