mercurial/fancyopts.py
changeset 52643 5cc8deb96b48
parent 51859 f4733654f144
child 52653 b3e68fd7864b
equal deleted inserted replaced
52642:73ab542565e0 52643:5cc8deb96b48
   239 
   239 
   240 
   240 
   241 class _callableopt(customopt):
   241 class _callableopt(customopt):
   242     def __init__(self, callablefn):
   242     def __init__(self, callablefn):
   243         self.callablefn = callablefn
   243         self.callablefn = callablefn
   244         super(_callableopt, self).__init__(None)
   244         super().__init__(None)
   245 
   245 
   246     def newstate(self, oldstate, newparam, abort):
   246     def newstate(self, oldstate, newparam, abort):
   247         return self.callablefn(newparam)
   247         return self.callablefn(newparam)
   248 
   248 
   249 
   249