[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]
Re: [p5p] pod bugs
> >If those who want to parse pod use a standard parser like Pod::Parser,
> >and Pod::Parser knows how to deal with blank lines, all problems are
> >over.
> 
> It has always been an attractive feature that Pod has been in theory
> trivially parsable in Perl without any fancydancy parsing modules.
> 
>     $/ = '';		# RTFM for what this means
>     while (<>) {	
> 	if (/^=/) { .... }
> 	....
>     } 
What if you were to write
      $/ = '';		# RTFM for what this means
      while (<>) {	
	for (split /^\s*$/m) {
  	  if (/^=/) { .... }
  	  ....
	}
      } 
Or some such, instead?  It seems to me that this is not outside the
boundary of `reasonable logic supported by Perl built-ins'.
- References to:
 - 
Tom Christiansen <tchrist@chthon.perl.com>
 
[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index][Thread Index][Top&Search][Original]