make termsem take a tmenv rather than a whole sig