Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions .github/typos.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
[default.extend-words]
Symplify = "Symplify"

Invokable = "Invokable"
24 changes: 24 additions & 0 deletions .github/workflows/typos.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# see https://github.com/crate-ci/typos
name: "Typos"

on:
pull_request:
push:
branches:
- "main"

jobs:
typos:
name: "Check for typos"
runs-on: "ubuntu-latest"

steps:
- uses: actions/checkout@v4



- name: "Check for typos"
uses: "crate-ci/[email protected]"
with:
config: .github/typos.toml
files: "README.md src config rules tests rules-tests"
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

namespace Rector\Tests\DowngradePhp73\Rector\FuncCall\DowngradeTrailingCommasInFunctionCallsRector\Fixture;

class InStirngVariable
class InStringVariable
{
public function run()
{
Expand All @@ -16,7 +16,7 @@ class InStirngVariable

namespace Rector\Tests\DowngradePhp73\Rector\FuncCall\DowngradeTrailingCommasInFunctionCallsRector\Fixture;

class InStirngVariable
class InStringVariable
{
public function run()
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@

namespace Rector\Tests\DowngradePhp74\Rector\ClassMethod\DowngradeCovariantReturnTypeRector\Fixture;

class InterableA
class IterableA
{
public function covariantReturnTypes(): iterable
{ /* … */ }
}

class InterableB extends InterableA
class IterableB extends IterableA
{
public function covariantReturnTypes(): array
{ /* … */ }
Expand All @@ -20,13 +20,13 @@ class InterableB extends InterableA

namespace Rector\Tests\DowngradePhp74\Rector\ClassMethod\DowngradeCovariantReturnTypeRector\Fixture;

class InterableA
class IterableA
{
public function covariantReturnTypes(): iterable
{ /* … */ }
}

class InterableB extends InterableA
class IterableB extends IterableA
{
/**
* @return mixed[]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
namespace Rector\Tests\DowngradePhp80\Rector\FuncCall\DowngradeSubstrFalsyRector\Fixture;

/**
* zero offset with postive length can't be false
* zero offset with positive length can't be false
*/
class SkipZeroOffsetWithPositiveLength
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ public function __construct(
) {
}

public function matchAncestorClassReflectionOverrideable(
public function matchAncestorClassReflectionOverridable(
ClassLike $classLike,
ClassMethod $classMethod
): ?ClassReflection {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ public function refactor(Node $node): ?Node
$hasChanged = false;

foreach ($node->getMethods() as $method) {
$ancestorOverridableAnonymousClass = $this->overrideFromAnonymousClassMethodAnalyzer->matchAncestorClassReflectionOverrideable(
$ancestorOverridableAnonymousClass = $this->overrideFromAnonymousClassMethodAnalyzer->matchAncestorClassReflectionOverridable(
$node,
$method
);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ public function __construct(

public function createFromArray(Array_ $array, MutatingScope $mutatingScope): FuncCall
{
$newArrayItems = $this->disolveArrayItems($array);
$newArrayItems = $this->dissolveArrayItems($array);
return $this->createArrayMergeFuncCall($newArrayItems, $mutatingScope);
}

Expand All @@ -40,7 +40,7 @@ public function createFromArray(Array_ $array, MutatingScope $mutatingScope): Fu
* to be added once the next spread is found, or at the end
* @return ArrayItem[]
*/
private function disolveArrayItems(Array_ $array): array
private function dissolveArrayItems(Array_ $array): array
{
$newItems = [];

Expand Down