@xjm, It's not clear to me which position you favor. Are you saying that we s...

Contribution Date
Technology
Contribution Project
Contribution Details

@xjm, It's not clear to me which position you favor. Are you saying that we should mark a BC break when we change a parameter name or the opposite?

Right now, I'm of the opinion that renaming a parameter should NOT constitute a BC break at least until we support PHP 7.4. I don't recollect if the minimum PHP version for Drupal 10 is already decided. If (and only if) the minimum is going to be PHP 8, then we could reconsider this position for Drupal 10 onwards (not earlier versions).

I agree that named arguments will help when we reorder parameters or add a parameter in between the parameters list (essentially reordering). But that only helps if all the callers use named arguments to call the function. AFAIK, there is no way to make it mandatory to use named arguments (sort of like kwargs in Python). Also, if a mandatory argument is added to the parameters, I am not sure how named arguments can help over there.

Issue Status
Active
Contribution Author
Files count
0
Patches count
0