Some functions (pgsql) converted from resource to object. However, the conditional typing is somehow broken for some functions. For me: pg_escape_literal and pg_escape_identifier, maybe others. I expect this is broken by some wrong type processing/evaluation, because the proper typing is present in PHPStorm stubs.
$connection = pg_connect("", PGSQL_CONNECT_FORCE_NEW);
if ($connection === false) return;
pg_escape_literal($connection, "test");
No error.
Bug report
Some functions (pgsql) converted from resource to object. However, the conditional typing is somehow broken for some functions. For me:
pg_escape_literalandpg_escape_identifier, maybe others. I expect this is broken by some wrong type processing/evaluation, because the proper typing is present in PHPStorm stubs.Code snippet that reproduces the problem
https://phpstan.org/r/11f31e1b-3464-4480-a43b-7a0b590b094a
Expected output
No error.