@@ -42,6 +42,7 @@ public function __construct($escapingMethod, $value)
4242 /**
4343 * Reset the array to the beginning (as required for the Iterator interface).
4444 */
45+ #[\ReturnTypeWillChange]
4546 public function rewind ()
4647 {
4748 reset ($ this ->value );
@@ -54,6 +55,7 @@ public function rewind()
5455 *
5556 * @return string The key
5657 */
58+ #[\ReturnTypeWillChange]
5759 public function key ()
5860 {
5961 return key ($ this ->value );
@@ -67,6 +69,7 @@ public function key()
6769 *
6870 * @return mixed The escaped value
6971 */
72+ #[\ReturnTypeWillChange]
7073 public function current ()
7174 {
7275 return sfOutputEscaper::escape ($ this ->escapingMethod , current ($ this ->value ));
@@ -75,6 +78,7 @@ public function current()
7578 /**
7679 * Moves to the next element (as required by the Iterator interface).
7780 */
81+ #[\ReturnTypeWillChange]
7882 public function next ()
7983 {
8084 next ($ this ->value );
@@ -91,6 +95,7 @@ public function next()
9195 *
9296 * @return bool The validity of the current element; true if it is valid
9397 */
98+ #[\ReturnTypeWillChange]
9499 public function valid ()
95100 {
96101 return $ this ->count > 0 ;
@@ -103,6 +108,7 @@ public function valid()
103108 *
104109 * @return bool true if the offset isset; false otherwise
105110 */
111+ #[\ReturnTypeWillChange]
106112 public function offsetExists ($ offset )
107113 {
108114 return isset ($ this ->value [$ offset ]);
@@ -115,6 +121,7 @@ public function offsetExists($offset)
115121 *
116122 * @return mixed The escaped value
117123 */
124+ #[\ReturnTypeWillChange]
118125 public function offsetGet ($ offset )
119126 {
120127 return sfOutputEscaper::escape ($ this ->escapingMethod , $ this ->value [$ offset ]);
@@ -132,6 +139,7 @@ public function offsetGet($offset)
132139 *
133140 * @throws sfException
134141 */
142+ #[\ReturnTypeWillChange]
135143 public function offsetSet ($ offset , $ value )
136144 {
137145 throw new sfException ('Cannot set values. ' );
@@ -148,6 +156,7 @@ public function offsetSet($offset, $value)
148156 *
149157 * @throws sfException
150158 */
159+ #[\ReturnTypeWillChange]
151160 public function offsetUnset ($ offset )
152161 {
153162 throw new sfException ('Cannot unset values. ' );
@@ -158,6 +167,7 @@ public function offsetUnset($offset)
158167 *
159168 * @return int The size of the array
160169 */
170+ #[\ReturnTypeWillChange]
161171 public function count ()
162172 {
163173 return count ($ this ->value );
0 commit comments