From: "Hal E. Fulton" Date: 2003-04-17T00:35:04+09:00 Subject: Re: regular expressions ----- Original Message ----- From: "Arthur Chance" <{spamtrap}@qeng-ho.org> Newsgroups: comp.lang.ruby To: "ruby-talk ML" Sent: Wednesday, April 16, 2003 8:12 AM Subject: Re: regular expressions > Well, a long time ago, in a very different world, there was a pattern > matching language called Snobol (or rather SNOBOL as punched cards > didn't have lower case :-). 30+ years ago I used to use it for the > sort of quick string manipulating hacks that Ruby and Perl often get > used for today. SNOBOL had "patterns" which weren't exactly today's > regexps but were very similar. I've often thought that a modern > variation of Snobol patterns would make a more user friendly regexp > syntax. > > [5 minutes later and I've found my old SNOBOL4 language manual, > copyright 1971. This takes me back.] [snip interesting SNOBOL stuff] First of all, it does my heart good to know that I am not actually the oldest person on this list. When you were programming in SNOBOL, I was barely in sixth grade, and the only computers I knew of were in _Star Trek_ reruns. More on-topic: I had an idea for "de-obfuscating" regexes a year or more ago; and I may even have mentioned it on the list. In fact, I think I did. Generally I wanted to use a notation that was more like a programming language (in a vein similar to the SNOBOL stuff you showed us) which could (e.g.) be put into here-documents and compiled into regular Ruby regexes. But eventually I was convinced that the Rockit parser could do everything I wanted to do (though in a somewhat different fashion, no doubt). So I abandoned that idea. I've never look at Rockit much. I assume it's in the RAA. But I'd be curious to know what a SNOBOL hacker thinks of it. Thanks, Hal