Fun with RACC examples

I've been browsing the Pragmatic Programmer book and was taken by the
"learn something new" statement.

Since parsers have always been interesting to me, I decided on racc.

I put together a sample that I found on cmills.freesheel.org
presentation and have put a copy of it here:

http://pastie.caboo.se/88816

Can any tell me why this doesn't work?

I'm using ruby 1.8.4 and racc version 1.4.5. Thanks for any guidance
you might provide.

Mike B.

Looks like I made a type on line 32 of the pastie. It reads:

when /\A\S+/o

and should be:

when /\A\s+/o

Yikes! :slight_smile:

Its surprising that there wasn't more conversation about this....is
there an elephant in the room that I can't see? :slight_smile:

It seemed like everywhere I went to look for information about this, I
read "yacc/racc is hard".

If folks aren't using stuff like this, what do they use instead?

Mike B.

···

On Aug 17, 4:00 pm, barjunk <barj...@attglobal.net> wrote:

I've been browsing the Pragmatic Programmer book and was taken by the
"learn something new" statement.

Since parsers have always been interesting to me, I decided onracc.

I put together a sample that I found on cmills.freesheel.org
presentation and have put a copy of it here:

http://pastie.caboo.se/88816

Can any tell me why this doesn't work?

I'm using ruby 1.8.4 andraccversion 1.4.5. Thanks for any guidance
you might provide.

Mike B.

<snip>

It seemed like everywhere I went to look for information about this, I
read "yacc/racc is hard".

If folks aren't using stuff like this, what do they use instead?

I looked at raac but the lack of docs put me off. Dhaka too much better in that respect and I am just about to start using it.

http://dhaka.rubyforge.org/

Dave.

···

On 22 Aug 2007, at 06:20, barjunk wrote:

Mike B.

Dave,

Thanks for pointing me to that. The good thing about dhaka seems that
there are recent posts, implying active development.

I looked at racc because it seemed to be "the standard" with regard to
what folks would most likely be able to help with if I ran into
trouble.

I'll give dhaka a try too and see what I can make of it.

Hopefully you'll post some of your experiences here as well.

Mike B.

···

On Aug 21, 11:57 pm, Dave Baldwin <dave.bald...@3dlabs.com> wrote:

On 22 Aug 2007, at 06:20, barjunk wrote:

<snip>

> It seemed like everywhere I went to look for information about this, I
> read "yacc/raccis hard".

> If folks aren't using stuff like this, what do they use instead?

I looked at raac but the lack of docs put me off. Dhaka too much
better in that respect and I am just about to start using it.

http://dhaka.rubyforge.org/

Dave.

> Mike B.