Re: [PHP-DEV] Deprecate posix_times

2023-11-04 Thread Jakub Zelenka
On Sat, Nov 4, 2023 at 11:40 AM Tim Düsterhus wrote: > Hi > > On 11/3/23 21:51, Jakub Zelenka wrote: > >> The main reason I would like to see this deprecated is not the fact that > >> it's returning a less precise value compared to getrusage, but rather > >> because it's returning a value that

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Saki Takamachi
Hi Kentaro, The case you presented certainly confuses us very much. Although it is outside the scope of this discussion, it certainly seems like it would be better to improve it from a safety perspective. BOOL probably has the most problems; for example, when you pass str, the boolean value

Re: [PHP-DEV] Deprecate posix_times

2023-11-04 Thread Tim Düsterhus
Hi On 11/3/23 21:51, Jakub Zelenka wrote: The main reason I would like to see this deprecated is not the fact that it's returning a less precise value compared to getrusage, but rather because it's returning a value that cannot be interpreted in any way from pure PHP. So if the constant is

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Kentaro Takeda via internals
Hi, internals. > As shown in the following issue, the behavior of `PDO::PARAM_` is > inconsistent and I would like to fix this. > https://github.com/php/php-src/issues/12603 I consider the current behavior a bug. And some of them contain behaviors that are very confusing to users. > It may

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Saki Takamachi
Hi Hans, Thank you, I will discuss it and improve it in a way that everyone is satisfied with. Saki -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: https://www.php.net/unsub.php

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Hans Henrik Bergan
I had no idea PDO's PARAM_INT and PARAM_BOOL was so buggy, good catch! On Sat, Nov 4, 2023, 07:59 Saki Takamachi wrote: > Hi internals, > > As shown in the following issue, the behavior of `PDO::PARAM_` is > inconsistent and I would like to fix this. >

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Saki Takamachi
Hi, Ayesh, I forgot to tell you one important thing. Binding of parameters is not actually done in the `bind`method, but in the `execute()` method. Therefore, when preparing a new method, a slightly larger mechanism is required to determine which method the parameter was set through.

Re: [PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Ayesh Karunaratne
> > Hi internals, > > As shown in the following issue, the behavior of `PDO::PARAM_` is > inconsistent and I would like to fix this. > https://github.com/php/php-src/issues/12603 > > First, I tried fixed pdo_pgsql. > https://github.com/php/php-src/pull/12605 > > Eventually I plan to make

[PHP-DEV] Fix the inconsistent behavior of PDO::PARAM_XXX

2023-11-04 Thread Saki Takamachi
Hi internals, As shown in the following issue, the behavior of `PDO::PARAM_` is inconsistent and I would like to fix this. https://github.com/php/php-src/issues/12603 First, I tried fixed pdo_pgsql. https://github.com/php/php-src/pull/12605 Eventually I plan to make similar changes to all