before and after methods

Didier Verna didier at lrde.epita.fr
Thu May 18 09:05:06 UTC 2017


Pascal Costanza wrote:

> I’m just guessing, but one reason I can think of is that almost all of
> the built-in method combinations (except for standard and progn) are
> applicative. before/after methods don’t have a direct impact on the
> return value of a generic function call, so their primary purpose is
> to allow for specifying side effects, which presumably doesn’t make a
> lot of sense for applicative combinators.
>
> Does that make any sense?

  Hmmm. Nope :-) Not much to me at least. I have several cases where I
  would have liked to be able to perform some kinds of sanity checks
  before executing a combination such as AND OR etc.

  I can still manage to do it in an around method, but it feels wrong.

-- 
Resistance is futile. You will be jazzimilated.

Lisp, Jazz, Aïkido: http://www.didierverna.info



More information about the pro mailing list