Define and use a new Choice.attemptNested function to replace a few uses of Choice.attempt which caused type-checking problems. Choice.attemptNested can be thought of as a bridge between Choice.attempt and pure (i.e., non-exception-raising) functions returning Choice.