Re: tough regex problem

Uri Guttman <[email protected]>
Newsgroups gmane.comp.lang.perl.fun
Message-ID <[email protected]>
>>>>> "QM" == Quantum Mechanic <[email protected]> writes:

  QM> Can you reverse the string and use lookahead?
  QM>   return split( m|(?=$sep)|, reverse ${$buf_ref} ) if
  QM> wantarray ;

this is file slurping. would you want the lines in reverse order? if so
you would use File::ReadBackwards :)

you could fix that with another list reverse but that all will be too
slow IMO. i have another solution i think which i will test later today.

uri

-- 
Uri Guttman  ------  [email protected]  -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs  ----------------------------  http://jobs.perl.org
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.