Skip to content

Commit

Permalink
Fix "can not" spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
mvorisek committed Oct 3, 2021
1 parent eb717fe commit 8ae89f4
Show file tree
Hide file tree
Showing 6 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion src/Cache/Cache.php
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public function toJson(): string

if (JSON_ERROR_NONE !== json_last_error()) {
throw new \UnexpectedValueException(sprintf(
'Can not encode cache signature to JSON, error: "%s". If you have non-UTF8 chars in your signature, like in license for `header_comment`, consider enabling `ext-mbstring` or install `symfony/polyfill-mbstring`.',
'Cannot encode cache signature to JSON, error: "%s". If you have non-UTF8 chars in your signature, like in license for `header_comment`, consider enabling `ext-mbstring` or install `symfony/polyfill-mbstring`.',
json_last_error_msg()
));
}
Expand Down
2 changes: 1 addition & 1 deletion src/Console/Command/DescribeCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ static function (string $type): string {

if (0 === \count($codeSamples)) {
$output->writeln([
'Fixing examples can not be demonstrated on the current PHP version.',
'Fixing examples cannot be demonstrated on the current PHP version.',
'',
]);
} else {
Expand Down
2 changes: 1 addition & 1 deletion src/FileReader.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
/**
* File reader that unify access to regular file and stdin-alike file.
*
* Regular file could be read multiple times with `file_get_contents`, but file provided on stdin can not.
* Regular file could be read multiple times with `file_get_contents`, but file provided on stdin cannot.
* Consecutive try will provide empty content for stdin-alike file.
* This reader unifies access to them.
*
Expand Down
4 changes: 2 additions & 2 deletions src/Fixer/Basic/PsrAutoloadingFixer.php
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,11 @@ public function supports(\SplFileInfo $file): bool
$tokens = Tokens::fromCode(sprintf('<?php class %s {}', $file->getBasename('.php')));

if ($tokens[3]->isKeyword() || $tokens[3]->isMagicConstant()) {
// name can not be a class name - detected by PHP 5.x
// name cannot be a class name - detected by PHP 5.x
return false;
}
} catch (\ParseError $e) {
// name can not be a class name - detected by PHP 7.x
// name cannot be a class name - detected by PHP 7.x
return false;
}

Expand Down
2 changes: 1 addition & 1 deletion src/Tokenizer/Token.php
Original file line number Diff line number Diff line change
Expand Up @@ -464,7 +464,7 @@ public function toJson(): string
if (JSON_ERROR_NONE !== json_last_error()) {
$jsonResult = json_encode(
[
'errorDescription' => 'Can not encode Tokens to JSON.',
'errorDescription' => 'Cannot encode Tokens to JSON.',
'rawErrorMessage' => json_last_error_msg(),
],
JSON_PRETTY_PRINT | JSON_NUMERIC_CHECK
Expand Down
2 changes: 1 addition & 1 deletion tests/Cache/CacheTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ public function testToJsonThrowsExceptionOnInvalid(): void
);

$this->expectExceptionMessage(
'Can not encode cache signature to JSON, error: "Malformed UTF-8 characters, possibly incorrectly encoded". If you have non-UTF8 chars in your signature, like in license for `header_comment`, consider enabling `ext-mbstring` or install `symfony/polyfill-mbstring`.'
'Cannot encode cache signature to JSON, error: "Malformed UTF-8 characters, possibly incorrectly encoded". If you have non-UTF8 chars in your signature, like in license for `header_comment`, consider enabling `ext-mbstring` or install `symfony/polyfill-mbstring`.'
);

$cache->toJson();
Expand Down

0 comments on commit 8ae89f4

Please sign in to comment.