A combination of parList and map, encapsulating a common pattern:
> parMap strat f = withStrategy (parList strat) . map f

Sequential function application. The argument is evaluated using the given strategy before it is given to the function.

Parallel function application. The argument is evaluated using the given strategy, in parallel with the function application.

Apply a transformation everywhere in bottom-up manner

Apply a transformation everywhere in top-down manner

Extend a generic query by a type-specific case

Type extension of queries for type constructors

ext2Q :: (Data d, Typeable2 t) => (d -> q) -> (forall d1 d2. (Data d1, Data d2) => t d1 d2 -> q) -> d -> q

Type extension of queries for type constructors

Put something inside an HTML element.

Sequential function composition. The result of the second function is evaluated using the given strategy, and then given to the first function.

Parallel function composition. The result of the second function is evaluated using the given strategy, in parallel with the application of the first function.

Sequential inverse function composition, for those who read their programs from left to right. The result of the first function is evaluated using the given strategy, and then given to the second function.

Parallel inverse function composition, for those who read their programs from left to right. The result of the first function is evaluated using the given strategy, in parallel with the application of the second function.

Make a generic query; start from a type-specific case; return a constant otherwise

Extend a generic transformation by a type-specific case

A fmap-like operator for builder primitives, both bounded and fixed size.
Builder primitives are contravariant so it's like the normal fmap, but backwards (look at the type). (If it helps to remember, the operator symbol is like ($) but backwards.)
We can use it for example to prepend and/or append fixed values to an primitive.
> showEncoding ((\x -> ('\'', (x, '\''))) >$< fixed3) 'x' = "'x'"
>
> fixed3 = char7 >*< char7 >*< char7
Note that the rather verbose syntax for composition stems from the requirement to be able to compute the size / size bound at compile time.

censor f m is an action that executes the action m and applies the function f to its output, leaving the return value unchanged.
* f m = pass (liftM (\x ->
> (x,f))

Make a generic transformation; start from a type-specific case; preserve the term otherwise

ext1T :: (Data d, Typeable1 t) => (forall e. Data e => e -> e) -> (forall f. Data f => t f -> t f) -> d -> d

Type extension of transformations for unary type constructors