Google Groups Home
Help | Sign in
Message from discussion implementation for Parsing Expression Grammar?
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
xahlee@gmail.com  
View profile
 More options May 10, 1:52 am
Newsgroups: comp.lang.perl.misc, comp.lang.python, comp.lang.lisp, comp.emacs, comp.lang.functional
From: "xah...@gmail.com" <xah...@gmail.com>
Date: Fri, 9 May 2008 22:52:30 -0700 (PDT)
Local: Sat, May 10 2008 1:52 am
Subject: implementation for Parsing Expression Grammar?
In the past weeks i've been thinking over the problem on the practical
problems of regex in its matching power. For example, often it can't
be used to match anything of nested nature, even the most simple
nesting. It can't be used to match any simple grammar expressed by
BNF. Some rather very regular and simple languages such as XML, or
even url, email address, are not specified as a regex. (there exist
regex that are pages long that tried to match email address though)

I wrote out a more elaborate account of my thoughts here:
 http://xahlee.org/cmaci/notation/pattern_matching_vs_pattern_spec.html

----------------

After days of researching this problem, looking into parsers and its
theories etc, today i found the answer!!

What i was looking for is called Parsing Expression Grammar (PEG).

See
http://en.wikipedia.org/wiki/Parsing_expression_grammar

It seems to me it's already in Perl6, and there's also a
implementation in Haskell. Is the perl6 PEG is in a usable state?

Thanks.

  Xah
  x...@xahlee.org
http://xahlee.org/



    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google