(in-package :cs325-user) ;;; inheritance examples ;;; note that concepts can be defined in any order ;;; or not defined at all (defmop dog (animal) :legs 4 :skin furred) (defmop buddy (chihuahua pet) :age 3) (defmop chihuahua (dog small-thing) :brain nil) (defmop pet (animal) :owner human) (defmop animal (living-thing)) (defmop living-thing (thing)) (defmop small-thing (thing) :size small) ;;; pedalo boat inheritance example from Ducournau (defmop boat (thing)) (defmop day-boat (boat) :navzone 5) (defmop wheel-boat (boat) :navzone 100) (defmop engineless-boat (day-boat)) (defmop small-multi-hull-boat (day-boat)) (defmop pedal-wheel-boat (engineless-boat wheel-boat)) (defmop small-catamaran (small-multi-hull-boat)) (defmop pedalo (pedal-wheel-boat small-catamaran))