mirror of
https://github.com/doctrine/orm.git
synced 2026-03-23 22:42:18 +01:00
[PR #9791] Deprecate calling setters without arguments #11885
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Original Pull Request: https://github.com/doctrine/orm/pull/9791
State: closed
Merged: Yes
Calling a setter without anything to set does not really make sense semantically. However, declaring
nullas the default value for a parameter used to be a common workaround to get a nullable typed parameter. This workaround is obsolete since PHP 7.1 introduced actual nullable types.This is why I'd like to get rid of those default values on setters.