On Feb 20, 5:37 pm, David Beazley <[email protected]> wrote:
> Maybe.  What does the parser.out file say about it?    The first state  
> should indicate the start rule.
>
> -Dave

---------------------------------------------
Created by PLY version 3.0 (http://www.dabeaz.com/ply)

Grammar

Rule 1     S' -> abstract_declarator_opt
Rule 2     abstract_declarator_opt -> empty
Rule 3     abstract_declarator_opt -> abstract_declarator
Rule 4     constant_expression_opt -> empty
Rule 5     constant_expression_opt -> constant_expression
---------------------------------------------

Bingo, it's not the rule I asked for with the 'start' argument.

Looking at the PLY-3 source code, it can be that you're ignoring this
argument in the yacc() interface function. You set the start with:

    # Set the grammar start symbols
    try:
        grammar.set_start(pinfo.start)
    except GrammarError:
        e = sys.exc_info()[1]
        errorlog.error(str(e))
        errors = 1

pinfo.start, AFAIK is what's reflected from my class, and you do
nothing with the 'start' argument to yacc().

Could this be it?

Eli


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"ply-hack" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/ply-hack?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to