If it didn't throw an error then there's still code somewhere which defines the puppy without inheriting the dog class.