code: def take_register(self, rtype = SharedData.TYPES.NO_TYPE):
          
          if len(self.free_registers) == 0:
              self.error("no more free registers")
          reg = self.free_registers.pop()
          self.used_registers.append(reg)
          self.symtab.set_type(reg, rtype)
          return reg
docs: Reserves one working register and sets its type