Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

That idea is first visible in OOP systems like COM, which depending on the language, or to use a more recent term from WinRT (language projection), exposes that capability.

Since COM only allows for interface inheritance, unlike SOM from OS/2 which also did classes, the way to avoid doing from scratch all members, is to compose and delegate all unmodified methods, while implementing only the new ones in an extended interface.

MFC, ATL, VB and Delphi provided some mechanisms to make this easier, naturally not at the same level as easyness done by Kotlin.

By the way, the same concept is available in Groovy, with @Delegate annotation.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: