|Exchange parameter, How? firstname.lastname@example.org (1995-06-24)|
|Re: Exchange parameter, How? email@example.com (1995-06-26)|
|From:||firstname.lastname@example.org (Alexander Dong)|
|Keywords:||lex, yacc, question, comment|
|Organization:||Technische Hochschule Darmstadt|
|Date:||Sat, 24 Jun 1995 04:29:10 GMT|
We have a special language.
This is the function declaration:
| parameters ',' one_parameter
So this language is simular to C. A function is like:
We want to write a program, which can exchange the parameters for us.
that is: function(b,a,d,c);
We are going to use LEX and YACC to do this. But we don't have the complete
grammar from this language. Is there a simple way to do this using lex & yacc
without to write the whole grammar?
Thanks very much!
[You can probably do well enough by just fiddling things that look like
function calls, looking lexically for a name followed by an open paren.
Return to the
Search the comp.compilers archives again.