Hi,
On 22.04.17 13:40, Colin O'Dell wrote:
Hello internals,
I'd like to propose an enhancement to curl_setopt()
<http://php.net/manual/en/function.curl-setopt.php> which is used to
configure a given curl session. The second argument of this function
defines which option to set and the third argument provides the
corresponding value to use.
Because each option expects the value to be a specific type, it makes sense
to enforce these types in strict type checking mode. I'd therefore like to
propose that we introduce strict type enforcement inside curl_setopt() when
"declare(strict_types=1);" is being used.
I'm sorry to say but I think this /approach/ is a horrible idea :(
To me the intention of strict types is clearly on the functions publicly
visible contract, i.e. it's reflectable parameters and not some business
logic hidden inside a function.
regards,
- Markus
--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php