If the data you want to pass is static (which I doubt, since there's little sense in using MIME::Decoder for static data), you could stick it at the end of your source after the
__DATA__ line and just pass around the *DATA filehandle. A quick hack that is possibly more flexible would be to pass *STDOUT as the input for whatever function you're dealing with and then print to it. Actually, that sounds too funky, but it's late and I can nail down why (blocking issues?). As
davorg mentioned above, your best bet is probably looking into using
tie for dynamic data.