DEV Community

Discussion on: Understanding SOLID Principles: Liskov Substitution Principle

Collapse
 
kodenix profile image
Alberto Morales

Instanceof is a antipattern, if you need add new subtypes, requiere add other validation and you client is hight coupled with subtypes, if you change the subtypes class need change on client ( break Open Close)