mirror of
https://github.com/danielstjules/Stringy.git
synced 2025-08-12 08:14:06 +02:00
Fix failing tests, remove PHP 5.4 short array syntax
This commit is contained in:
@@ -126,7 +126,7 @@ echo S::swapCase($string, 'UTF-8'); // 'fÒÔ bÀŘ'
|
||||
|
||||
## Implemented Interfaces
|
||||
|
||||
`Stringy\Stringy` implements the IteratorAggregate interface. This allows you
|
||||
`Stringy\Stringy` implements the `IteratorAggregate` interface. This allows you
|
||||
to use `foreach` with an instance of the class:
|
||||
|
||||
``` php
|
||||
|
@@ -74,12 +74,12 @@ class StringyTestCase extends CommonTest
|
||||
{
|
||||
$stringy = S::create('Fòô Bàř', 'UTF-8');
|
||||
|
||||
$valResult = [];
|
||||
$valResult = array();
|
||||
foreach ($stringy as $char) {
|
||||
$valResult[] = $char;
|
||||
}
|
||||
|
||||
$keyValResult = [];
|
||||
$keyValResult = array();
|
||||
foreach ($stringy as $pos => $char) {
|
||||
$keyValResult[$pos] = $char;
|
||||
}
|
||||
|
Reference in New Issue
Block a user