Skip to content

Commit c7c8c89

Browse files
committed
Treat Redis::isConnected as non-deterministic
1 parent 490050c commit c7c8c89

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

bin/functionMetadata_original.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,10 @@
170170
'DateTimeImmutable::getTimestamp' => ['hasSideEffects' => false],
171171
'DateTimeImmutable::getTimezone' => ['hasSideEffects' => false],
172172

173+
// affects isConnected()
174+
'Redis::connect' => ['hasSideEffects' => true],
175+
'Redis::pconnect' => ['hasSideEffects' => true],
176+
173177
'SplDoublyLinkedList::pop' => ['hasSideEffects' => true],
174178
'SplDoublyLinkedList::shift' => ['hasSideEffects' => true],
175179

resources/functionMetadata.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -452,6 +452,8 @@
452452
'NumberFormatter::getPattern' => ['hasSideEffects' => false],
453453
'NumberFormatter::getSymbol' => ['hasSideEffects' => false],
454454
'NumberFormatter::getTextAttribute' => ['hasSideEffects' => false],
455+
'Redis::connect' => ['hasSideEffects' => true],
456+
'Redis::pconnect' => ['hasSideEffects' => true],
455457
'ReflectionAttribute::getArguments' => ['hasSideEffects' => false],
456458
'ReflectionAttribute::getName' => ['hasSideEffects' => false],
457459
'ReflectionAttribute::getTarget' => ['hasSideEffects' => false],

0 commit comments

Comments
 (0)