In theory "
410 Gone" is supposed to be "Gone for good, Never coming back".
In practice, many sites do have pages that come back having been 410 status at some time in the past, so Google does still look a couple of times per year to make sure the status is still 410.
Imagine you bought a domain name from someone, and root
example.com/ had been returning
410 Gone for the last three years. If
410 Gone literally meant Gone Forever, you could never get your new home page indexed.
In the real world there are many things that "reset" or "override" the previously recorded Gone status, but I would never want to rely on that behaviour. So, 404 for some things and 410 for others it is.
P.S. A Google search for "perl equivalent of php include" may be useful.