Moose uses this regexp from Package::Stash::PP to check the package name:
elsif ($package !~ /\A[0-9A-Z_a-z]+(?:::[0-9A-Z_a-z]+)*\z/) { confess "$package is not a module name"; }
or is it a regular expression from Package::Stash::XS :
const char *vmre = "\\A[0-9A-Z_a-z]+(?:::[0-9A-Z_a-z]+)*\\z";
But you can create your own package installation in the Package::Stash namespace and use it by setting the PACKAGE_STASH_IMPLEMENTATION environment PACKAGE_STASH_IMPLEMENTATION or the $Package::Stash::IMPLEMENTATION variable before loading Package::Stash . For example, if your implementation is named Package::Stash::My , then set the variable to My .
source share