Mysterious stuff found in the long grass

My folks have a pear tree at the end of the garden. It never really produces much in the way of fruit - I think it's too close to the much bigger apple tree. I found this pear lying on the ground in some long grass. It has a weird pattern of holes made in a perfect spiral along the fruit. What happened?