terms with hyphens in them break

This fixes that.

Also FYI it looks like the prefix guess test fails (also XML::NamespaceFactory should croak rather than die), and make distclean removes stuff under version control. I didn't touch those.

And it might be worth contemplating switching to Moo to trim down the startup time. But that's a different issue.