[erlang-bugs] R17A - Bug : unwanted semi-colon in generated erlang module after yecc compilation.

Peer Stritzinger peerst@REDACTED
Mon Oct 28 13:07:26 CET 2013


My minmal testcase for reproducing this is this short yrl grammar:

BTW tried this even with R15B01 and it also triggers:

----- test.yrl -----
Nonterminals
pgdl rels rel.

Terminals
SYM 'role' '(' ')'.

Rootsymbol pgdl.

pgdl -> rels : '$1' .

rels -> rels rel :  '$1' ++ ['$2'] .

rel -> '(' 'role' SYM ')' : {role, '$1'} .
----- test.yrl -----

 $ erlc tst.yrl
$ erlc tst.erl
tst.erl:209: syntax error before: ';'
tst.erl:191: function yeccpars2_0/7 undefined

the output part that triggers this compilation error is:
--------
…
yeccpars2(Other, _, _, _, _, _, _) ->
 erlang:error({yecc_bug,"1.4",{missing_state_in_action_table, Other}}).

;
yeccpars2_0(_, _, _, _, T, _, _) ->
 yeccerror(T).
…
--------

Cheers,
Peer Stritzinger






On 2013-10-28 11:34:56 +0000, Anthony Ramine said:

> Forwarding to Richard Carlsson, ping?






More information about the erlang-bugs mailing list