I have a small file of pod documentation and I would like to have a hash with keys being the head1 text (NAME, VERSION, AUTHOR etc) and value being the raw data of the lines read up to the next =head1.
I have subclassed Pod::Simple::PullParser to have the text value after head1, but my problem is to have the unparsed lines (including this =head1 XXX) I saw that there is a raw_mode in the the _accessorize list in Pod::Simple and I have tried this code in my subclass package Myparser; use base qw(Pod::Simple::PullParser); ... sub new { my $self = shift; my $new = $self->SUPER::new(@_); $new->{'output_fh'} ||= *STDOUT{IO}; $new->_accessorize('raw_mode'=>1); return $new; } But this does not seems to change the ouput of $token->text for example. Thanks for any help François