Пример #1
0
 def report_error(self, e):
     # ignore if already an error
     if self.has_errors:
         return
     self.has_errors = True
     self.cpu_state = CPU.CPUState()
     self.cpu_state.get(self.cpu)
     if isinstance(e, VamosError):
         self.vamos_error = e
     else:
         self.other_error = e
         exc_type, exc_value, exc_traceback = sys.exc_info()
         self.other_tb = traceback.extract_tb(exc_traceback)
         self.other_type = exc_type
         self.other_value = exc_value