so yeah, `withSound()` should return the same type...
# announcements
p
so yeah,
withSound()
should return the same type as it is defined in
b
This seems to me to be a pretty nonsensical idea in the first place. Why does an animal know how to return a different type of animal? Why is withSound() an instance function in the first place? Either just make it a static method or create a simple builder: https://pastebin.com/7Pv1yHij