feat(kernel/justification): make sure the code does not depend on the argument order of evaluation generated by a compiler

see issue #618
This commit is contained in:
Leonardo de Moura 2015-05-21 07:42:10 -07:00
parent 89581cead7
commit 76e7f2e7d8

View file

@ -310,11 +310,11 @@ format justification::pp_core(formatter const & fmt, pos_info_provider const * p
return format(format("Assumption "), format(to_assumption(it)->m_idx)); return format(format("Assumption "), format(to_assumption(it)->m_idx));
else else
return format(); return format();
case justification_kind::Composite: case justification_kind::Composite: {
return format r1 = to_composite(it)->m_child[0].pp_core(fmt, p, s, set, is_main);
to_composite(it)->m_child[0].pp_core(fmt, p, s, set, is_main) + format r2 = to_composite(it)->m_child[1].pp_core(fmt, p, s, set, false);
to_composite(it)->m_child[1].pp_core(fmt, p, s, set, false); return r1 + r2;
} }}
} }
format justification::pp(formatter const & fmt, pos_info_provider const * p, substitution const & s) const { format justification::pp(formatter const & fmt, pos_info_provider const * p, substitution const & s) const {