-
-
Notifications
You must be signed in to change notification settings - Fork 441
Expand file tree
/
Copy pathdanielstjules-stringy-src-stringy-php.patch
More file actions
48 lines (48 loc) · 1.83 KB
/
Copy pathdanielstjules-stringy-src-stringy-php.patch
File metadata and controls
48 lines (48 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
--- /dev/null
+++ ../src/Stringy.php
@@ -267,6 +267,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
*
* @return int The number of characters in the string, given the encoding
*/
+ #[\ReturnTypeWillChange]
public function count()
{
return $this->length();
@@ -450,6 +451,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
*
* @return \ArrayIterator An iterator for the characters in the string
*/
+ #[\ReturnTypeWillChange]
public function getIterator()
{
return new ArrayIterator($this->chars());
@@ -847,6 +849,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
* @param mixed $offset The index to check
* @return boolean Whether or not the index exists
*/
+ #[\ReturnTypeWillChange]
public function offsetExists($offset)
{
$length = $this->length();
@@ -870,6 +873,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
* @throws \OutOfBoundsException If the positive or negative offset does
* not exist
*/
+ #[\ReturnTypeWillChange]
public function offsetGet($offset)
{
$offset = (int) $offset;
@@ -890,6 +894,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
* @param mixed $value Value to set
* @throws \Exception When called
*/
+ #[\ReturnTypeWillChange]
public function offsetSet($offset, $value)
{
// Stringy is immutable, cannot directly set char
@@ -903,6 +908,7 @@ class Stringy implements Countable, IteratorAggregate, ArrayAccess
* @param mixed $offset The index of the character
* @throws \Exception When called
*/
+ #[\ReturnTypeWillChange]
public function offsetUnset($offset)