79075388

Date: 2024-10-10 16:43:02
Score: 2.5
Natty:
Report link

In the case where there is or might be hundreds of invokers of this event, changing the signature of the MyEventArgs would require a lot of refactoring. The existence of the parameter "object sender" allows for a late hack without requiring a refactor of all occurrences. (or if recipients need to handle new arguments of MyEventArgs)

Although, this does not tell if the pattern is better or not, because patterns are subjective. It may or may not be better, contextually depending.

This answer is heavily inspired from a comment on this question made by @Ralf

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • User mentioned (1): @Ralf
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Ky9432