Skip to content

Commit

Permalink
Updated Rector to commit 886efb0d938e35698fbffbb485550997ef280ff0
Browse files Browse the repository at this point in the history
rectorphp/rector-src@886efb0 [NodeTypeResolver] Clean up unnecessary scope attribute set on Class_/Interface_/Enum_ (#6316)
  • Loading branch information
TomasVotruba committed Sep 19, 2024
1 parent b76a31f commit 4929adc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/Application/VersionResolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,12 +19,12 @@ final class VersionResolver
* @api
* @var string
*/
public const PACKAGE_VERSION = '71a0da85b79bb112bdf2f8ac88fc9034a88a0f6e';
public const PACKAGE_VERSION = '886efb0d938e35698fbffbb485550997ef280ff0';
/**
* @api
* @var string
*/
public const RELEASE_DATE = '2024-09-18 14:55:38';
public const RELEASE_DATE = '2024-09-18 23:59:42';
/**
* @var int
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,6 @@ public function processNodes(array $stmts, string $filePath, ?MutatingScope $for
/** @var MutatingScope $mutatingScope */
$mutatingScope = $this->resolveClassOrInterfaceScope($node, $mutatingScope);
$node->setAttribute(AttributeKey::SCOPE, $mutatingScope);
$this->decorateNodeAttrGroups($node, $mutatingScope, $nodeCallback);
return;
}
if ($node instanceof Trait_) {
Expand All @@ -173,11 +172,11 @@ public function processNodes(array $stmts, string $filePath, ?MutatingScope $for
if (!$node instanceof VirtualNode) {
$node->setAttribute(AttributeKey::SCOPE, $mutatingScope);
}
$this->decorateNodeAttrGroups($node, $mutatingScope, $nodeCallback);
if ($node instanceof FileWithoutNamespace) {
$this->nodeScopeResolverProcessNodes($node->stmts, $mutatingScope, $nodeCallback);
return;
}
$this->decorateNodeAttrGroups($node, $mutatingScope, $nodeCallback);
if (($node instanceof Expression || $node instanceof Return_ || $node instanceof EnumCase || $node instanceof Cast) && $node->expr instanceof Expr) {
$node->expr->setAttribute(AttributeKey::SCOPE, $mutatingScope);
return;
Expand Down

0 comments on commit 4929adc

Please sign in to comment.