cursor-0.6

C

Caleb Clausen

I am very interested in Cursor for use in Reg. It seems like the sort
of thing to allow Reg's Array-based backtracking pattern matcher to
operate on Strings or Files or whatever else.
(Did you know that I needed this by esp? :) Since you're got your own
lexer/parser/pattern matcher thing, (grammar?) maybe you don't want to
help the competition...

Anyway, cursor isn't quite functional enough for my purposes. Passing
patterns for the length parameter to #get and #set is great, but there
aren't enough pattern types. I think I need the equivalent of
Cursor#=3D=3D=3D(regexp), which is to say, the ability to compare a Regexp
to a position within a String. Or, if the backing store of the cursor
is a file, you get the ability to compare a Regexp to a File. Someone
was asking for that recently, it's not easy, but it would be great if
your lib did it.... just the ability to regexp against the middle of a
String would make me very happy, tho. I've hacked this up before, but
I think that a reasonably efficient version would require a bit of c
extension.

Ideally, of course, I want to see the ability to compare against a
Reg, particularly the Regs that match multiple array elements. If you
made it work with whatever the equivalent in your system is, that
would be almost as good.

How does Grammar work? I would appreciate if you could write a couple
of paragraphs of high-level overview of Cursor, Grammar, their design
and capabilites and how they're intended to work together.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,172
Messages
2,570,934
Members
47,477
Latest member
ColumbusMa

Latest Threads

Top