I've had a right old time today. It started with something pretty simple, be able to freeze and thaw regular expressions with Storable.
It didn't work easily, and I've had to go down roads I've not been down before (namely, XS). So I'm a little nervous about sending it out onto CPAN. However, if people want to be able to:
use Storable qw( freeze thaw );
my $struct = freeze( qr/a pattern/ );
my $re = thaw( $struct );
all they need to do is download and install http://www.ululate.co.uk/code/Regexp-Copy-0.01.tar.gz and stick:
use Regexp::Copy;
at the top. Provided no-one uses it and finds that it goes horribly wrong then I'll release it on to CPAN in the next couple of days.