Skip to content

Conversation

@samsonasik
Copy link
Member

@samsonasik samsonasik commented Jun 11, 2025

On this code:

final class MultipleDefault extends Exception
{
    public function __construct(string $message)
    {
        parent::__construct($message, 0, null);
    }
}

0 and null are default parameters, so both needs to be removed.

-        parent::__construct($message, 0, null);
+        parent::__construct($message);

@samsonasik
Copy link
Member Author

samsonasik commented Jun 11, 2025

The issue is on ValueResolver itself, which convert null to string "null"

if ($expr instanceof ConstFetch) {
return $this->nodeNameResolver->getName($expr);
}

as it returns name on ConstFetch

@samsonasik
Copy link
Member Author

samsonasik commented Jun 11, 2025

Fixed by show returns value on null, true, and false on ValueResolver 4276016

@samsonasik
Copy link
Member Author

All checks have passed 🎉 @TomasVotruba I am merging it ;)

@samsonasik samsonasik merged commit f2621f9 into main Jun 11, 2025
45 checks passed
@samsonasik samsonasik deleted the multiple-de branch June 11, 2025 15:45
@github-actions
Copy link
Contributor

This pull request has been automatically locked because it has been closed for 150 days. Please open a new PR if you want to continue the work.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 28, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants