From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.5-pre1 (2020-06-20) on ip-172-31-74-118.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-1.9 required=3.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.5-pre1 Path: eternal-september.org!reader02.eternal-september.org!.POSTED!not-for-mail From: Paul Rubin Newsgroups: comp.lang.ada Subject: Re: Easiest way to use redular expressions? Date: Tue, 05 Jan 2021 02:46:24 -0800 Organization: A noiseless patient Spider Message-ID: <87ft3facfz.fsf@nightsong.com> References: Mime-Version: 1.0 Content-Type: text/plain Injection-Info: reader02.eternal-september.org; posting-host="ab45c146ff4cdd315463ecb59dc851b8"; logging-data="18628"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX199J4PVOAV0qh7weNrv8nYM" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Cancel-Lock: sha1:xYSJ/pXJElx3VkIy4/Za2l3Mkwg= sha1:BbEZ1g2Oo3i5hrN1hgmPsiAKgEw= Xref: reader02.eternal-september.org comp.lang.ada:61034 List-Id: "Dmitry A. Kazakov" writes: > If somebody is adamant to use patterns, then SNOBOL would be a better > choice. It is cleaner, intuitive and more powerful than regular > expressions. OMG, SNOBOL was fun, but these days, look at Parsec-style parser combinators. Parsec is a Haskell library but there are similar things in other languages. > (There is a SPITBOL implementation in GNAT libraries. It is fun to look at, written in an abstract assembly language with a SPITBOL program that translates it to various real assembly languages. It is fun to read the source code, which is extremely well commented. SPITBOL was originally written by Robert Dewar (of Adacore) and Ken Belcher, fwiw.