[php-src] Issue #7900: `never` return type for arrow functions with throw expressions

From: Date: Fri, 07 Jan 2022 10:21:04 +0000
Subject: [php-src] Issue #7900: `never` return type for arrow functions with throw expressions
Groups: php.bugs 
Request: Send a blank email to php-bugs+get-238845@lists.php.net to get a copy of this message
Issue: https://github.com/php/php-src/issues/7900 Comment Author: bwoebi The general problem is that return <expr> is forbidden at compile-time (which the short closure expands to). Now, if we loosen this restriction, we have to completely get rid of the compile-time check, for short closures, and just check at runtime. (We cannot just see throw, because calling another function returning never is equally valid.)

« previous php.bugs (#238845) next »