Persistent lexical variable values for arbitrary callshttp://search.cpan.org/dist/Lexical-Persistence/
Lexical::Persistence does a few things, all related. Note that all the
behaviors listed here are the defaults. Subclasses can override nearly every
aspect of Lexical::Persistence's behavior.
Lexical::Persistence lets your code access persistent data through lexical
variables. This example prints "some value" because the value of $x perists in
the $lp object between setter() and getter().