Inching along in my work on
        https://core.tcl.tk/akupries/marpa/timeline

I have come across a weirdness/bogosity regarding the retrieval of the
valuation instructions (steps) from a `Marpa_Value`.

First, on the good side, the relevant method (get-parse) in the bocage
glue class [1] works just fine. Whether for the lexer or the parser, I
properly get all the steps (tokens, rules, nullings, etc).

On the other hand, in the structurally identical functions for the
C-level runtime I am now working on (lexer [2], parser [3]) I see only
2 types of step types: "token" and "inactive". Rule and nulling steps
are missing (and I placed the TRACE commands such that I really should
see everything coming out of `marpa_v_step`).

I have no idea what is going with the Marpa_Value. I actually can see
where in the list of steps the rules should show up, by looking at the
stack locations coming with the token steps.  I.e. I see token(value)s
getting pushed on the stack, dst-slot increasing and then a token
suddenly writes into the middle instead of the top. Implying that at
least one rule is in between them, doing reductions. But that rule
instruction was not returned by `marpa_v_step`.

I am pretty sure that the grammar and recognizer are correct, simply
because I do get the proper lexemes out of the system [4] instead of a
parse error.

Anybody with an idea what I might be doing wrong ?

[1] https://core.tcl.tk/akupries/marpa/artifact/b840a1e9de9c9e42?ln=130-274
[2] https://core.tcl.tk/akupries/marpa/artifact/b28b552a320a424d?ln=383-464
[3] https://core.tcl.tk/akupries/marpa/artifact/ab0d46ff4344c06e?ln=162-288
[4] At the lexer level the token steps alone are good enough to at
    least know that.

-- 
See you,
        Andreas Kupries <akupr...@shaw.ca>
                        <http://core.tcl.tk/akupries/>
        Developer @     SUSE (MicroFocus Canada LLC)
                        <andreas.kupr...@suse.com>

Tcl'2017, Oct 16-20, Houston, TX, USA. http://www.tcl.tk/community/tcl2017/
-------------------------------------------------------------------------------




-- 
You received this message because you are subscribed to the Google Groups 
"marpa parser" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to marpa-parser+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to