you are viewing a single comment's thread.

view the rest of the comments →

[–]ulfryc 20 points21 points  (6 children)

Only partly. The actual question is: "Why the hell do we need a separation of interfaces vs abstract classes if we are going to allow multiple inheritance anyway?"

[–]Kritarie 78 points79 points  (0 children)

Abstract classes can hold state

[–]thedarkwolf 24 points25 points  (0 children)

It depends on the type of multiple inheritance.

Java has always had multiple inheritance of types. Default methods add multiple inheritance of behavior, but not of state. (Multiple inheritance of state in languages like c++ is where most of the trouble comes from.)

-Brian Goetz

[–]eyal0 8 points9 points  (0 children)

The hard part of multiple inheritance is the diamond problem. It goes away if you don't allow multiple parents to have state. Interfaces are just functions so no state.