Re: Regexp Alternatives (was Re: Wondering what I'm doing wrong?)
"David McClain (as dbm at refined-audiometrics dot com)" <[email protected]> Thu, 11 Jun 2026 19:14:35 -0700
| Newsgroups | gmane.lisp.lispworks.general |
|---|---|
| Message-ID | <[email protected]> |
>> Yes, I’ll give it a go. But there is no equivalent for SBCL, and I was trying for portability. > Yabbut we *are* talking on a LW mailing list :) > Yes we are. My preferred weapon has always been LW, for the past 35 years. But I’m an old dude, and with inflation raging the way it is, I might not be able to afford my LW Licenses someday. And I don’t want to be caught without some Lisp for me to use. I have also found that. when possible, keeping things portable is helpful for others. But some things in LW simply don’t have any equivalent. AFIAK, the Async Socket protocol is a huge one in favor of LW. > On Jun 11, 2026, at 18:13, Adam Weaver (as adam at cleversure dot com dot au) <[email protected]> wrote: > > Re-arranged, because top-posting is a sin. > >>> On Jun 11, 2026, at 17:45, Adam Weaver (as adam at cleversure dot com dot au) <[email protected]> <mailto:[email protected]> wrote: >>> >>> DM, I don't suppose you're interested in trying your number parser out >>> using LW's built-in PARSERGEN package? > > > On 12/6/26 09:05, David McClain wrote: >> Yes, I’ll give it a go. But there is no equivalent for SBCL, and I was trying for portability. > Yabbut we *are* talking on a LW mailing list :) > >> Also, IIRC, the Parsergen in LW needs a lexical analyzer built for it. All my other parsers do the lexical analysis in stride as part of the parsing. > True, but that's easily fixed with some macrology. ** > > I might have a crack at this over the weekend - distraction over doing Real Work instead :) > >> The one thing I found, about Parseq (dunno yet about ESRAP), unlike a regexp matcher where you can anchor the pattern to the end of the line, you have to manually do your anchoring in the parsing grammar. I do that with an EOS Rule: >> >> (defrule eos () (* char) >> (:test (&rest es) >> (null es))) > Noice. > > A > > ** I did once experiment with some read-macrology to convert a PCRE style regexp into the built-in Lispworks regexp format (which I think was Emacs inspired). It was fuuuuuuuuuuuggggggleeeeeeeeeeee. >