Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 94ee5d5fdb
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
Coverage Report for CI Build 25187232264Coverage decreased (-0.4%) to 97.003%Details
Uncovered ChangesNo uncovered changes found. Coverage Regressions2 previously-covered lines in 1 file lost coverage.
Coverage Stats
💛 - Coveralls |
|
@codex review |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f34e2fb06a
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| { | ||
| foreach ($nodes as $node) { | ||
| if ($node instanceof Namespace_) { | ||
| if ($node->name->toString() === $this->namespace) { |
There was a problem hiding this comment.
Handle anonymous namespace node before comparing names
Guard this comparison against Namespace_ nodes whose name is null (for example, files using namespace { ... } global blocks). In that case, calling toString() throws at runtime, so setNamespace() crashes instead of rewriting the file. This regression is input-dependent but affects valid PHP files that parse to anonymous namespace nodes.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
Anonymous namespaces cannot be PSR-4 autoloaded, so this case is intentionally not supported.
No description provided.