in reply to save to file: $h{'sub'}=sub{..};
You can use B::Deparse to create a string from a coderef that you can then eval back to the coderef again.
The latest version of Data::Dumper can do this for you. Take a look at the $Data::Dumper::Deparse switch.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: save to file: $h{'sub'}=sub{..};
by Anonymous Monk on Jul 12, 2003 at 19:10 UTC | |
|
Re: Re: save to file: $h{'sub'}=sub{..};
by Anonymous Monk on Jul 13, 2003 at 11:39 UTC | |
by Anonymous Monk on Jul 13, 2003 at 11:50 UTC | |
by Anonymous Monk on Jul 13, 2003 at 12:03 UTC | |
by adrianh (Chancellor) on Jul 13, 2003 at 16:05 UTC |