The flexibility of the fold will soon have us defining lots of little one- or
two-line functions for various tasks. Each of these definitions will need a little
function like sem or syn ... but as we define more of
these, and especially if we add one or two cases to the definition of the operator
symbol types (e.g. AOp or BOp), these short multi-line
definitions will become a bit tedious. We can make these definitions much more
succinct by using what amounts to a fold for an enumerated type, here called aop.
|
|