finish the typed PCF semantics