Optimized constant subs are stored as bare scalars in the stash (package hash), which formerly held only GVs (typeglobs).
But you cant create them manually - you cant assign a scalar to a stash element, and expect it to work like a constant-sub, even if you provide a prototype.
This is a feature; alternative is too much action-at-a-distance. The following test demonstrates - napier is not seen as a function at all, much less an optimized one.
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 426:
Unknown directive: =head