comp.lang.ada
 help / color / mirror / Atom feed
From: Georg Bauhaus <rm.dash-bauhaus@futureapps.de>
Subject: Re: GNAT.Regpat problem.
Date: Thu, 24 Mar 2011 17:41:09 +0100
Date: 2011-03-24T17:41:09+01:00	[thread overview]
Message-ID: <4d8b7425$0$6989$9b4e6d93@newsspool4.arcor-online.net> (raw)
In-Reply-To: <alpine.WNT.2.00.1103241003330.4896@WHIRLWIND>

On 24.03.11 15:04, Peter C. Chapin wrote:
> On Thu, 24 Mar 2011, Dmitry A. Kazakov wrote:
> 
>> Just curious, why are you using regular expressions when GNAT offers Spitbol
>> patterns?
> 
> Spitbol patterns seemed like overkill.

Just yesterday I wrote me a SPITBOL program to
rummage in log files.  That was quickly done,
performed as expected, and nothing got killed
except the bugs that got traced in the log.

The trick is to use simple patterns. (They are typed,
and can be debugged incrementally as needed. That's
unlike UNIX V7 RE strings, which either work, or don't
work, but how do you inject tracing the point of
failure?)

FTR, in SNOBOL-4 syntax,

        Space = " " CHAR(9)
        Pattern = POS(0) (SPAN(Space) | NULL) "xyzzy" RPOS(0)



      parent reply	other threads:[~2011-03-24 16:41 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-22 18:35 GNAT.Regpat problem Peter C. Chapin
2011-03-22 19:01 ` Georg Bauhaus
2011-03-22 19:17 ` Florian Weimer
2011-03-22 19:21 ` Adam Beneschan
2011-03-22 20:31   ` Simon Wright
2011-03-24 10:23     ` Peter C. Chapin
2011-03-24 10:43       ` Dmitry A. Kazakov
2011-03-24 14:04         ` Peter C. Chapin
2011-03-24 14:34           ` Dmitry A. Kazakov
2011-03-24 16:20             ` Georg Bauhaus
2011-03-24 17:37               ` Dmitry A. Kazakov
2011-03-24 21:12             ` Peter C. Chapin
2011-03-25  9:02               ` Dmitry A. Kazakov
2011-03-24 16:41           ` Georg Bauhaus [this message]
replies disabled

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox