[climacs-devel] Re: regex

Lawrence Mitchell wencel at gmail.com
Wed May 4 16:09:21 UTC 2005


Hi there,

Nicolas Sceaux wrote:

> Hello,

> Some months ago, there was a discussion about adapting cl-ppcre for
> use with climacs buffers iso. plain strings.

>   http://common-lisp.net/pipermail/climacs-devel/2005-January/000077.html

> I would like to know if maybe someone (Lawrence?) had got some
> results, and eventually some advices to give, before putting my noze
> inside the beast.

I started looking at this, and then, unfortunately, real life
intervened, so I haven't had much of a chance to get things
working.

I had a very trivial proof-of-concept implementation that just
turned buffers into strings and then matched on them, obviously,
this is far from ideal.

After discussing alternatives here and with Edi, it seems like
the way forward is to modify cl-ppcre to change all occurances of
(SCHAR *STRING* ...) and the like in the sources to some function
that returns a character in a Climacs buffer.

That is, rather than doing (scan regex string) and then matching
in string, do (scan regex buffer) and somehow match in buffer.
This is around the point that I got not much further.  I didn't
manage to figure out a way to make this work nicely and didn't
get round to figuring out what was wrong before other work
intervened.

Sorry not to have any better news really, I'll probably have more
time come the end of May but won't really be able to look at
things before that.  I can send you what I do have (non-working)
so far if you're interested.

cheers,

Lawrence




More information about the climacs-devel mailing list