Well well well. This is your third post in a very short period, each one with a slightly different attempt at a really simple grammar for Parse::RecDescent.

I'm wondering whether you've actually read the perldoc man page for that module. If you've read it, I'm wondering why you're still trying the same basic approach as your first post.

(BTW, have you looked recently for updates and sub-replies to your earlier posts? I put an update or sub-reply on your previous thread, that explains about using "/$/" in a parser rule, to make sure the parser covers an entire input string, and this seems to be relevant to the current thread.)

I'm also wondering why you haven't tried to provide more detail about the sorts of user input you're trying to handle, and/or the sorts of feedback you want to provide to the user, and/or whether you really want to do anything with the parser results, apart from telling whether the input text is parsable or not.

It seems as though you're not getting some very basic concept about parser/grammar design, or about the sort of approach your app should be using, based on what you expect it to do (which has not been made very clear, yet).

And you certainly don't seem to be getting the hints about how to post code at the Monastery -- please read the part about code tags at Writeup Formatting Tips, and use that information.

Also start showing a little more effort in using ideas that have been provided, and exploring a broader range of approaches on your own. Otherwise, people might just decide you're too dense to learn anything, and they'll loose interest in answering your questions. (You might even get downvoted -- ack! .... just kidding; I would never do that. ;)


In reply to Re: Parse::Recdescent rule problem by graff
in thread Parse::Recdescent rule problem by hak0983

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.