Bug #81082 [NEW]: PDO::getAttribute() requires mixed return type

From: Date: Wed, 26 May 2021 05:55:28 +0000
Subject: Bug #81082 [NEW]: PDO::getAttribute() requires mixed return type
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-234019@lists.php.net to get a copy of this message
From: corey dot taylor dot fl at gmail dot com Operating system: PHP version: master-Git-2021-05-26 (Git) Package: PDO Core Bug Type: Bug Bug description:PDO::getAttribute() requires mixed return type Description: ------------ With the addition of tentative return types for PDO, we saw this new deprecation show up in generated mock code. Declaration of Mock_PDO_f5cc810f::getAttribute(int $attribute) should be compatible with PDO::getAttribute(int $attribute): mixed This requires the use of the new mixed return type available in php 8 only. Isn't the return type mixed when omitted and therefore compatible with the declared tentative return type? https://3v4l.org/sVfS7/rfc#git.master -- Edit bug report at https://bugs.php.net/bug.php?id=81082&edit=1 -- Fix committed: https://bugs.php.net/fix.php?id=81082&r=fixed Fixed in release: https://bugs.php.net/fix.php?id=81082&r=alreadyfixed Need backtrace: https://bugs.php.net/fix.php?id=81082&r=needtrace Need Reproduce Script: https://bugs.php.net/fix.php?id=81082&r=needscript Try newer version: https://bugs.php.net/fix.php?id=81082&r=oldversion Not developer issue: https://bugs.php.net/fix.php?id=81082&r=support Expected behavior: https://bugs.php.net/fix.php?id=81082&r=notwrong Not enough info: https://bugs.php.net/fix.php?id=81082&r=notenoughinfo Submitted twice: https://bugs.php.net/fix.php?id=81082&r=submittedtwice register_globals: https://bugs.php.net/fix.php?id=81082&r=globals PHP version support discontinued: https://bugs.php.net/fix.php?id=81082&r=phptooold Daylight Savings: https://bugs.php.net/fix.php?id=81082&r=dst IIS Stability: https://bugs.php.net/fix.php?id=81082&r=isapi Install GNU Sed: https://bugs.php.net/fix.php?id=81082&r=gnused Floating point limitations: https://bugs.php.net/fix.php?id=81082&r=float No Zend Extensions: https://bugs.php.net/fix.php?id=81082&r=nozend MySQL Configuration Error: https://bugs.php.net/fix.php?id=81082&r=mysqlcfg

« previous php.bugs (#234019) next »