Converts a XML name into a valid perl name (valid for subroutines, variables
or the like).
perl_name takes a crude approach by just replacing . and - (dot and dash)
with a underscore. This may or may not be sufficient, and may or may not
provoke collisions in your XML names.