/* additional tokens introduced by splint pre-processor. */
%token <tok> LLMACRO LLMACROITER LLMACROEND TENDMACRO
+/* For debugging purposes */
+%token <tok> QDREVEALSTATE
+
/* break comments: */
%token <tok> QSWITCHBREAK QLOOPBREAK QINNERBREAK QSAFEBREAK
%token <tok> QINNERCONTINUE
%type <entry> endIter
%type <funcclauselist> functionClauses functionClausesPlain
-%type <funcclause> functionClause functionClause functionClausePlain
+%type <funcclause> functionClause functionClausePlain
%type <globsclause> globalsClause globalsClausePlain
%type <modsclause> modifiesClause modifiesClausePlain nomodsClause
%type <expr> orIterExpr conditionalIterExpr assignIterExpr iterArgExpr
%type <expr> expr optExpr constantExpr
%type <expr> init macroBody iterBody endBody partialIterStmt iterSelectionStmt
-%type <expr> stmt stmtList fcnBody iterStmt iterDefStmt iterDefStmtList
+%type <expr> stmt stmtList fcnBody iterStmt iterDefStmt iterDefStmtList debugStmt
%type <expr> labeledStmt caseStmt defaultStmt
%type <expr> compoundStmt compoundStmtAux compoundStmtRest compoundStmtAuxErr
%type <expr> expressionStmt selectionStmt iterationStmt jumpStmt iterDefIterationStmt
$$ = idDecl_replaceCtype ($1, ct);
/*drl 7/25/01 added*/
- setImplictfcnConstraints();
+ setImplicitfcnConstraints();
DPRINTF((message("namedDeclBase PushType TLPAREN TRPAREN...:\n adding implict constraints to functionClause List: %s",
functionClauseList_unparse($6)
)
));
- fcl = functionClauseList_setImplictConstraints($6);
+ fcl = functionClauseList_setImplicitConstraints($6);
idDecl_addClauses ($$, fcl);
functionClauses
{
functionClauseList fcl;
- setImplictfcnConstraints ();
+ setImplicitfcnConstraints ();
clearCurrentParams ();
$$ = idDecl_replaceCtype ($1, ctype_makeFunction (idDecl_getCtype ($1), $4));
)
)) ;
- fcl = functionClauseList_setImplictConstraints($7);
+ fcl = functionClauseList_setImplicitConstraints($7);
idDecl_addClauses ($$, fcl);
structDeclList DeleteStructInnerScope { sRef_clearGlobalScopeSafe (); }
TRBRACE
optStructInvariant
- { ctype ct; ct = declareStruct ($3, $8); context_setGlobalStructInfo(ct, $12); $$ = ct; }
+ { ctype ct; ct = declareStruct ($3, $8); /* context_setGlobalStructInfo(ct, $12); */ $$ = ct; }
| NotType CUNION newId IsType TLBRACE { sRef_setGlobalScopeSafe (); }
CreateStructInnerScope
structDeclList DeleteStructInnerScope { sRef_clearGlobalScopeSafe (); }
| iterationStmt
| iterStmt
| jumpStmt
+ | debugStmt
;
+debugStmt
+ : QDREVEALSTATE TLPAREN expr TRPAREN { exprNode_revealState ($3); $$ = exprNode_undefined; }
+;
iterBody
: iterDefStmtList { $$ = $1; }
| iterationStmtErr
| TLPAREN stmtErr TRPAREN { $$ = exprNode_addParens ($1, $2); }
| jumpStmt
+ | debugStmt
| error { $$ = exprNode_makeError (); }
;