def _type_to_yices(self, tp): if tp.is_bool_type(): return yicespy.yices_bool_type() elif tp.is_real_type(): return yicespy.yices_real_type() elif tp.is_int_type(): return yicespy.yices_int_type() elif tp.is_function_type(): stps = [self._type_to_yices(x) for x in tp.param_types] rtp = self._type_to_yices(tp.return_type) #arr = (yicespy.type_t * len(stps))(*stps) return yicespy.yices_function_type(len(stps), stps, rtp) elif tp.is_bv_type(): return yicespy.yices_bv_type(tp.width) else: raise NotImplementedError(tp)