News for hackers. Stuff that matters.
Re:App Developers on Swift Evolution by winstonewert on Tuesday December 22, 2015 @07:58PM (#10781407)
Sure, it only affects you. The problem is that changes to superclass can now break your code.

For example, perhaps right now the function looks like this:

    def get(self, url, method='GET'):
        ...

    def post(self, url):
        self.get(url, method='POST')
You override get, to add some additional functionality. All is fine.

Then somebody realizes that the original code was silly, and rewrites it:

    def get(self, url, method='GET'):
        if method != 'GET':
           print "DEPRECATED!"
        self.request(url, method=method)

    def post(self, url):
        self.request(url, method='POST')
It seems to do the same thing, and probably passes all the same tests. But suddenly, now your code doesn't get called for post requests and your additional functionality breaks in a mysterious way.

Perhaps its still your fault for doing a bad job subclassing, but its going to look like its the fault of the person who fixed the parent class.

Re:App Developers on Swift Evolution by dplgk on Sunday January 03, 2016 @02:49PM (#10832016)
> changes to superclass can now break your code

The same exact thing happens when using composition.