Factored out a small utility from the Clash of the Lambdas.