How to use the choose function for large values of N?

I am using the stan::math::choose function which fails if you try large values of N, e.g. choose(40, 20) -> “choose: n choose k is … but must be less than or equal to 2147483647”.

Is there something in Stan that replicates the choose or lchoose functions from R so that large outputs can be obtained?

> rstan::lookup("lchoose")
                StanFunction        Arguments ReturnType Page
53  binomial_coefficient_log (real x, real y)       real   35
232                  lchoose (real x, real y)       real   36