From 77fc1d1ec92ae9f77708166b6d5d97ff177c2d9c Mon Sep 17 00:00:00 2001 From: ndossche <7771979+ndossche@users.noreply.github.com> Date: Sun, 31 May 2026 23:17:51 +0200 Subject: [PATCH] Fix -Werror compile error in `zend_dval_to_lval_cap()` This makes imagick CI fail on PHP 8.5: ``` /usr/include/php/20250925/Zend/zend_operators.h: In function 'zend_dval_to_lval_cap': /usr/include/php/20250925/Zend/zend_operators.h:149:88: error: unused parameter 's' [-Werror=unused-parameter] 149 | static zend_always_inline zend_long zend_dval_to_lval_cap(double d, const zend_string *s) | ~~~~~~~~~~~~~~~~~~~^ cc1: all warnings being treated as errors ``` --- Zend/zend_operators.h | 1 + 1 file changed, 1 insertion(+) diff --git a/Zend/zend_operators.h b/Zend/zend_operators.h index 57bcdd8d6ae4..5478e164c178 100644 --- a/Zend/zend_operators.h +++ b/Zend/zend_operators.h @@ -148,6 +148,7 @@ static zend_always_inline zend_long zend_dval_to_lval_silent(double d) /* Used to convert a string float to integer during an (int) cast */ static zend_always_inline zend_long zend_dval_to_lval_cap(double d, const zend_string *s) { + ZEND_IGNORE_VALUE(s); if (UNEXPECTED(!zend_finite(d))) { return 0; } else if (!ZEND_DOUBLE_FITS_LONG(d)) {