in reply to Loading PERL Module from scalar in RAM?

@INC has a hook mechanism, where you can place a callback instead of a string path.

The callback can decide to return the code if encountered by require while working thru @INC.

The interface is a bit convoluted but it works. After adding the hook inside BEGIN you can call use or require deeply hidden inside foreign code and your "RAM modules" are installed.

quotes from the docs

...

edit

here some example code from an older discussion

in that case the code is fetched via HTTP, but it should be easy to to just fill in your RAM stuff instead.

Cheers Rolf
(addicted to the 𐍀𐌴𐍂𐌻 Programming Language :)
Wikisyntax for the Monastery