[PECL-CVS] [pecl-math-stats] master: Fixed return type for stats_rand_gen_t()

[email protected] (Mikhail Galanin) Tue, 21 Apr 2026 02:50:58 +0000
Newsgroups php.pecl.cvs
Message-ID <[email protected]>
Author: Mikhail Galanin
Pusher: rlerdorf
Date: 2023-02-24T11:16:41Z

Commit: https://github.com/php/pecl-math-stats/commit/aae217edc1407391baf621211e06c166d38c0503
Raw diff: https://github.com/php/pecl-math-stats/commit/aae217edc1407391baf621211e06c166d38c0503.diff

Fixed return type for stats_rand_gen_t()

Changed paths:
  M  stats.stub.php
  M  stats_arginfo.h


Diff:

diff --git a/stats.stub.php b/stats.stub.php
index 8b6b006..2071100 100644
--- a/stats.stub.php
+++ b/stats.stub.php
@@ -43,7 +43,7 @@ function stats_rand_ibinomial(int $n, float $pp): int|false {}
 function stats_rand_ibinomial_negative(int $n, float $p): int|false {}
 function stats_rand_gen_ipoisson(float $mu): int|false {}
 function stats_rand_gen_noncentral_t(float $df, float $xnonc): float|false {}
-function stats_rand_gen_t(float $df): array|false {}
+function stats_rand_gen_t(float $df): float|false {}
 function stats_dens_normal(float $x, float $ave, float $stdev): float|false {}
 function stats_dens_cauchy(float $x, float $ave, float $stdev): float|false {}
 function stats_dens_laplace(float $x, float $ave, float $stdev): float|false {}
diff --git a/stats_arginfo.h b/stats_arginfo.h
index 3c99ebf..ab92a6b 100644
--- a/stats_arginfo.h
+++ b/stats_arginfo.h
@@ -1,5 +1,5 @@
 /* This is a generated file, edit the .stub.php file instead.
- * Stub hash: e6cfe06b9c3e187348f16fd6a34bb7eafc5042d9 */
+ * Stub hash: 2dca8eb298b57b9da45d9270b4bc97de0faad1aa */
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_stats_cdf_t, 0, 3, MAY_BE_DOUBLE|MAY_BE_FALSE)
 	ZEND_ARG_TYPE_INFO(0, par1, IS_DOUBLE, 0)
@@ -137,9 +137,7 @@ ZEND_END_ARG_INFO()
 
 #define arginfo_stats_rand_gen_noncentral_t arginfo_stats_rand_gen_noncentral_chisquare
 
-ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_stats_rand_gen_t, 0, 1, MAY_BE_ARRAY|MAY_BE_FALSE)
-	ZEND_ARG_TYPE_INFO(0, df, IS_DOUBLE, 0)
-ZEND_END_ARG_INFO()
+#define arginfo_stats_rand_gen_t arginfo_stats_rand_gen_chisquare
 
 ZEND_BEGIN_ARG_WITH_RETURN_TYPE_MASK_EX(arginfo_stats_dens_normal, 0, 3, MAY_BE_DOUBLE|MAY_BE_FALSE)
 	ZEND_ARG_TYPE_INFO(0, x, IS_DOUBLE, 0)