mirror of
https://github.com/verilator/verilator.git
synced 2025-01-07 15:17:36 +00:00
Add funcRef grammer object - no functional change
git-svn-id: file://localhost/svn/verilator/trunk/verilator@855 77ca24e4-aefa-0310-84f0-b9a241c72d87
This commit is contained in:
parent
ce531c5a67
commit
11335fae5f
@ -111,6 +111,7 @@ class AstSenTree;
|
|||||||
AstCase* casep;
|
AstCase* casep;
|
||||||
AstCaseItem* caseitemp;
|
AstCaseItem* caseitemp;
|
||||||
AstConst* constp;
|
AstConst* constp;
|
||||||
|
AstFuncRef* funcrefp;
|
||||||
AstModule* modulep;
|
AstModule* modulep;
|
||||||
AstPin* pinp;
|
AstPin* pinp;
|
||||||
AstRange* rangep;
|
AstRange* rangep;
|
||||||
@ -250,6 +251,7 @@ class AstSenTree;
|
|||||||
%type<varrefp> lhIdVarRef
|
%type<varrefp> lhIdVarRef
|
||||||
%type<varnodep> lhIdVarXRef
|
%type<varnodep> lhIdVarXRef
|
||||||
%type<taskrefp> taskRef
|
%type<taskrefp> taskRef
|
||||||
|
%type<funcrefp> funcRef
|
||||||
%type<nodep> idRanged lhIdRanged
|
%type<nodep> idRanged lhIdRanged
|
||||||
%type<nodep> idArrayed lhIdArrayed
|
%type<nodep> idArrayed lhIdArrayed
|
||||||
%type<nodep> strAsInt strAsText lhConcIdList
|
%type<nodep> strAsInt strAsText lhConcIdList
|
||||||
@ -800,8 +802,7 @@ exprNoStr: expr yOROR expr { $$ = new AstLogOr ($2,$1,$3); }
|
|||||||
| yD_TIME { $$ = new AstTime($1); }
|
| yD_TIME { $$ = new AstTime($1); }
|
||||||
| yD_UNSIGNED '(' expr ')' { $$ = new AstUnsigned($1,$3); }
|
| yD_UNSIGNED '(' expr ')' { $$ = new AstUnsigned($1,$3); }
|
||||||
|
|
||||||
| yID '(' eList ')' { $$ = new AstFuncRef($2,*$1,"",$3); }
|
| funcRef { $$ = $1; }
|
||||||
| pathDotted '.' yID '(' eList ')' { $$ = new AstFuncRef($4,*$3,*$1,$5); }
|
|
||||||
|
|
||||||
| yINTNUM { $$ = new AstConst(CRELINE(),*$1); }
|
| yINTNUM { $$ = new AstConst(CRELINE(),*$1); }
|
||||||
|
|
||||||
@ -983,6 +984,10 @@ taskRef: yID { $$ = new AstTaskRef(CRELINE(),*$1,"",NULL);}
|
|||||||
| pathDotted '.' yID '(' eList ')' { $$ = new AstTaskRef(CRELINE(),*$3,*$1,$5);}
|
| pathDotted '.' yID '(' eList ')' { $$ = new AstTaskRef(CRELINE(),*$3,*$1,$5);}
|
||||||
;
|
;
|
||||||
|
|
||||||
|
funcRef: yID '(' eList ')' { $$ = new AstFuncRef($2,*$1,"",$3); }
|
||||||
|
| pathDotted '.' yID '(' eList ')' { $$ = new AstFuncRef($4,*$3,*$1,$5); }
|
||||||
|
;
|
||||||
|
|
||||||
idArrayed: idVarXRef { $$ = $1; }
|
idArrayed: idVarXRef { $$ = $1; }
|
||||||
| idArrayed '[' expr ']' { $$ = new AstSelBit($2,$1,$3); } // Or AstArraySel, don't know yet.
|
| idArrayed '[' expr ']' { $$ = new AstSelBit($2,$1,$3); } // Or AstArraySel, don't know yet.
|
||||||
;
|
;
|
||||||
|
Loading…
Reference in New Issue
Block a user