Skip to content

Commit

Permalink
Fixed component_reference
Browse files Browse the repository at this point in the history
git-svn-id: https://openmodelica.org/svn/OpenModelica/trunk@267 f25d12d1-65f4-0310-ae8a-bbce733d8d8e
  • Loading branch information
x97davka committed Apr 9, 1998
1 parent dbeb3c6 commit 7c0f714
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions modeq/ast/modgram.g
Expand Up @@ -748,13 +748,14 @@ name_path : << bool qualified = false; >>
/* name_path b:LBRACK^ subscript_list RBRACK! */
/* ; */

component_reference : << void *tail = NULL; >>
component_reference : << void *tail = NULL;>>
i:IDENT^ { a:subscripts }
<< #i->rml = mk_box2(0,
mk_scon($i.u.stringval),
#a ? #a->rml : mk_nil()); >>
<< #i->rml = mk_scon($i.u.stringval); >>
{ dot:DOT^ c:component_reference << tail = #c->rml; >> }
<< #0->rml = mk_cons(#i->rml, tail != NULL ? tail : mk_nil()); >>
<< if(tail)
#0->rml = Exp__CREF_5fQUAL(#i->rml, #a?#a->rml:mk_nil(), tail);
else
#0->rml = Exp__CREF_5fIDENT(#i->rml, #a?#a->rml:mk_nil()); >>
;

/* not in document's grammar */
Expand Down

0 comments on commit 7c0f714

Please sign in to comment.