fix error reporting in unify.ml to report the first error instead of a
rather confusing absent/present clash
Fix bugs with unifying session variables.