This repository was archived by the owner on Feb 22, 2023. It is now read-only.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you think there's a case where a platform implementation would ever deliberately want to be broken instead of getting a runtime error method added to them silently? In some cases I could see people preferring to be obviously broken by newer versions instead of having to figure out themselves if there's any new methods that will throw runtime errors. But I'm not sure if that's reasonable.
If you think it's theoretically possible that some people would prefer to be broken at compile time by new versions, I think this should be reworded to something like "Additions to this class aren't treated as breaking changes. Be careful if you choose to implement instead of extend this class as you will be broken by newly added methods instead of getting default implementations."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a really good question.
I think that ideally we wouldn't want builds to be broken after upgrading a minor version of a dependency. If we allow platform implementers to implement this class then every addition to this class is a breaking change and requires a major version bump (potentially to the platform interface which may be versioned separately). Technically this is also the case for any method addition to any class.
I see how treating additions to this class as breaking change can make sense, though it's a longer discussion so not dumping my thoughts on this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense.