[tpm] I wish I was better at regex's

Uri Guttman uri at StemSystems.com
Wed Mar 9 13:30:09 PST 2011

>>>>> "JBL" == J Bobby Lopez <jbl at jbldata.com> writes:

  JBL> I would expect that you can just count the number of ';'
  JBL> instances in the string, and get the index of the last instance
  JBL> which resides after the last instance of the last single or
  JBL> double quote.  If there are no quotes, then it's the first
  JBL> instance of ';'.

that is backwards. it is much simpler to parse forwards. this is old
school stuff that is done in assemblers and similar syntaxes with
optional fields on a line. you scan allowed fields from left to right
and it all is easy.


Uri Guttman  ------  uri at stemsystems.com  --------  http://www.sysarch.com --
-----  Perl Code Review , Architecture, Development, Training, Support ------
---------  Gourmet Hot Cocoa Mix  ----  http://bestfriendscocoa.com ---------

More information about the toronto-pm mailing list