in reply to Is 'use vars' really obsolete?

If I understand your question correctly, what you are asking for is exactly what our provides. You just need to use a fully qualified name when outside the package.

See the first example in the docs: https://perldoc.perl.org/functions/our.html