Path: utzoo!utgpu!news-server.csri.toronto.edu!mailrus!uflorida!ziggy!usfvax2!tct!chip From: chip@tct.uucp (Chip Salzenberg) Newsgroups: comp.lang.perl Subject: Re: User Definable Character Classes Message-ID: <260176EA.C58@tct.uucp> Date: 16 Mar 90 23:29:46 GMT References: <15253@bfmny0.UU.NET> <7420@jpl-devvax.JPL.NASA.GOV> Organization: ComDev/TCT, Sarasota, FL Lines: 26 According to lwall@jpl-devvax.JPL.NASA.GOV (Larry Wall): >I'm looking carefully at ways to integrate better argument parsing with >regular expressions. Right now it's not possible to, say, swap the >second and third arguments of a function call, at least not with complete >generality. You need to have some means of tokenizing, and rejecting >commas and right parens that are inside parens or quotes or comments, or, >depending on the language, after backslashes or dollar signs. Sounds like a job for: lex.pl :-) What we could use here is a full-blown lexical analyis engine integrated into the Perl language. For example, the RCS file format is an ASCII stream with "@" delimeters, where "@@" means a literal "@". I've often wondered how to write Perl to interpret such a file without calling getc thousands of times. Then again, if I want flex, I know where to find it. -- Chip Salzenberg at ComDev/TCT , "The Usenet, in a very real sense, does not exist."