Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions lib/special_cases.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ function apcu_fetch($key)
}

/**
* @template TKey of array-key
*
* Searches subject for matches to
* pattern and replaces them with
* replacement.
Expand Down Expand Up @@ -117,7 +119,7 @@ function apcu_fetch($key)
* 'strlen(\'$1\')+strlen("$2")'). Make sure you are
* aware of PHP's string
* syntax to know exactly how the interpreted string will look.
* @param string|array|string[] $subject The string or an array with strings to search and replace.
* @param string|array<TKey, string> $subject The string or an array with strings to search and replace.
*
* If subject is an array, then the search and
* replace is performed on every entry of subject,
Expand All @@ -129,7 +131,7 @@ function apcu_fetch($key)
* replacements done.
* @param-out int $count
*
* @return string|array|string[] preg_replace returns an array if the
* @return ($subject is array ? array<TKey, string> : string) preg_replace returns an array if the
* subject parameter is an array, or a string
* otherwise.
*
Expand Down