Extracts the subgraphs from the parameters of a statement that applies a
higher-order primitive, such as the branches of prim_if() or the body
of prim_while().
This is not recursive: only the subgraphs held directly by statement are
returned, not the ones nested in the statements of those subgraphs. Call
subgraphs() on their statements to descend further.