Weekly Dev Tips

Liskov Substitution

07.29.2019 - By Steve Smith (@ardalis)Play

Download our free app to listen on your phone

Download on the App StoreGet it on Google Play

This is episode 53, on the Liskov Substitution principle. The typical definition used today is that subtypes should always be substitutable for their base types. If this isn't the case, it likely means you have the wrong inheritance relationship, or your interface isn't cohesive enough, or there is some other code smell you should consider addressing through refactoring.

More episodes from Weekly Dev Tips