Applicatives model computations in which values computed by subcomputations cannot affect what subsequent computations will take place. Relative to monads, this restriction takes power away from the user of the interface and gives it to the implementation. In particular, because the structure of the entire computation is known, one can augment its definition with some description of that structure.
For more information, see:
Applicative Programming with Effects.
Conor McBride and Ross Paterson.
Journal of Functional Programming 18:1 (2008), pages 1-13.
http://staff.city.ac.uk/~ross/papers/Applicative.pdfmodule type Basic : sig ... endmodule type Basic_using_map2 : sig ... endmodule type S : sig ... endmodule type Basic2 : sig ... endmodule type Basic2_using_map2 : sig ... endmodule type S2 : sig ... endmodule S_to_S2 = Base.Applicative_intf.S_to_S2This module serves mostly as a partial check that S2 and S are in sync, but
actually calling it is occasionally useful.
module S2_to_S = Base.Applicative_intf.S2_to_Smodule type Args2 : sig ... endmodule Args_to_Args2 = Base.Applicative_intf.Args_to_Args2module Make_using_map2 : functor (X : Basic_using_map2) -> S with type a t := a X.tmodule Make2_using_map2 : functor (X : Basic2_using_map2) -> S2 with type (a, e) t := (a, e) X.tThe following functors give a sense of what Applicatives one can define.
Of these, Of_monad is likely the most useful. The others are mostly didactic.