1--TEST-- 2Test array_product() function with objects castable to numeric type 3--EXTENSIONS-- 4gmp 5--FILE-- 6<?php 7$input = [gmp_init(25), gmp_init(6)]; 8 9echo "array_product() version:\n"; 10var_dump(array_product($input)); 11 12echo "array_reduce() version:\n"; 13var_dump(array_reduce($input, fn($carry, $value) => $carry * $value, 1)); 14?> 15--EXPECT-- 16array_product() version: 17int(150) 18array_reduce() version: 19object(GMP)#5 (1) { 20 ["num"]=> 21 string(3) "150" 22} 23