diff options
Diffstat (limited to 'src/Components')
-rw-r--r-- | src/Components/Array2d.php | 6 | ||||
-rw-r--r-- | src/Components/OptionsArray.php | 6 |
2 files changed, 10 insertions, 2 deletions
diff --git a/src/Components/Array2d.php b/src/Components/Array2d.php index 64dea40..1660959 100644 --- a/src/Components/Array2d.php +++ b/src/Components/Array2d.php @@ -85,7 +85,11 @@ class Array2d extends Component if ($count === -1) { $count = $arrCount; } elseif ($arrCount != $count) { - $parser->error("{$count} values were expected, but found {$arrCount}.", $token); + $parser->error( + '%1$d values were expected, but found %2$d.', + $token, + array($count, $arrCount) + ); } $ret[] = $arr; $state = 1; diff --git a/src/Components/OptionsArray.php b/src/Components/OptionsArray.php index 487eefd..d1b9952 100644 --- a/src/Components/OptionsArray.php +++ b/src/Components/OptionsArray.php @@ -137,7 +137,11 @@ class OptionsArray extends Component // real options (e.g. if there are 5 options, the first // fake ID is 6). if (isset($ret->options[$lastOptionId])) { - $parser->error('This option conflicts with \'' . $ret->options[$lastOptionId] . '\'.', $token); + $parser->error( + 'This option conflicts with "%1$s".', + $token, + array($ret->options[$lastOptionId]) + ); $lastOptionId = $lastAssignedId++; } } else { |