I have a Bison rule
block: LBRACE { some code } decls stmts RBRACE {more code }
;
The issue is in the "more code" section, I have
$$ = $3 ;
Basically, I want the return value of block to be stmts. When I do this, Bison says "$3 of block has no type." If I remove the code block containing some code and stick it into the latter block, bison does not complain. I have stmts and all of its derivatives declared as types. So is this not allowed by Bison? I can make changes to the grammar to accommodate this, but it will be tedious and much easier to just use the above.