@@ -553,7 +553,7 @@ XSF_HOST_DEVICE inline std::complex<double> hyp2f1(double a, double b, double c,
553
553
* the series at a or b of smaller magnitude. This is to ensure proper
554
554
* handling of situations like a < c < b <= 0, a, b, c all non-positive
555
555
* integers, where terminating at a would lead to a term of the form 0 / 0. */
556
- std:: uint64_t max_degree;
556
+ double max_degree;
557
557
if (a_neg_int || b_neg_int) {
558
558
if (a_neg_int && b_neg_int) {
559
559
max_degree = a > b ? std::abs (a) : std::abs (b);
@@ -562,7 +562,7 @@ XSF_HOST_DEVICE inline std::complex<double> hyp2f1(double a, double b, double c,
562
562
} else {
563
563
max_degree = std::abs (b);
564
564
}
565
- if (max_degree <= UINT64_MAX) {
565
+ if (max_degree <= ( double ) UINT64_MAX) {
566
566
auto series_generator = detail::HypergeometricSeriesGenerator (a, b, c, z);
567
567
return detail::series_eval_fixed_length (series_generator, std::complex<double >{0.0 , 0.0 }, max_degree + 1 );
568
568
} else {
@@ -583,7 +583,7 @@ XSF_HOST_DEVICE inline std::complex<double> hyp2f1(double a, double b, double c,
583
583
* (DLMF 15.8.1) */
584
584
if (c_minus_a_neg_int || c_minus_b_neg_int) {
585
585
max_degree = c_minus_b_neg_int ? std::abs (c - b) : std::abs (c - a);
586
- if (max_degree <= UINT64_MAX) {
586
+ if (max_degree <= ( double ) UINT64_MAX) {
587
587
result = std::pow (1.0 - z, c - a - b);
588
588
auto series_generator = detail::HypergeometricSeriesGenerator (c - a, c - b, c, z);
589
589
result *=
0 commit comments