
Oct. 11, 2018
12:43 p.m.
A link on https://en.wikipedia.org/wiki/Liskov_substitution_principle goes to http://www.engr.mun.ca/~theo/Courses/sd/5895-downloads/sd-principles-3.ppt.p... which has a very nice example (slides 14 and 15). Slide 14: Is immutable Square a behavioural subtype of immutable Rectangle? And vice versa? Slide 15: Is mutable Square a behavioural subtype of mutable Rectangle? And vice versa? And relationship between mutable and immutable Square (resp Rectangle). -- Jonathan