yep....exactly..... But either way Boost has a pretty good regex library and that's compiled.
As for someone saying "Regular expressions" are used when there is weak structure from a computability standpoint, regexes break down to D/NFAs whereas a parser equates to a PDA and a true semantic checker requires a turning machine equivalent. Personally I'd say if you thought it through regexes may get used in parsers when there is bad grammatical structure but a regex is the easiest, simpelest, most well defined structure there is. -Tom ps that mastering regular expressions book is pretty cool pps PERL does stuf that aren't even really true regular expressions like backreferences ppps I learned PERL from Nat Torkington at Qualcomm so I may be biased. On Wed, 23 Mar 2005 16:21:26 -0800, Andrew P. Lentvorski, Jr. <[EMAIL PROTECTED]> wrote: > > On Mar 23, 2005, at 2:43 PM, Brian Deacon wrote: > > > I'm not often in regex world, so somebody probably phrased a better > > version of this observation already.... but I joked with my friend that > > regex is an example of the signal to noise ratio being too -high-. > > Actually, I don't agree. And, it seems, neither do most programmers. > > The big problem is that regexes get used when there is weak structure > to what you are parsing. When there is weak structure, there is > ambiguity. Where there is ambiguity, there is complexity--eg. headers > for email. > > When you have structure, just about anything will work. XML, > s-expressions, grammar parsers, etc. > > > Anybody know of anything like that? > > flex and bison and other things of their ilk (grammar parsers and > lexers) would probably be what you describe. > > -a > > -- > [email protected] > http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list > -- [email protected] http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list
