Hi Green, Thanks for your detail explanation. I think that I made a mistake. The bison version which I used is 1.28, not 1.35, so errors are produced. Thanks Shulong Kelly Green wrote: > Shulong.Wu@xxxxxxxxxxxx wrote: > > >Hi all > > > >When I use bison to convert the ICM parser Yacc file (ibis-icm-yacc.y) > >to C program, like this: > > > >/usr/bin/bison -d -p ICM ibis-icm-yacc.y > > > >It produces many errors, like these: > > > >ibis-icm-yacc.y:587: invalid @-construct > > > >ibis-icm-yacc.y:587: $. is invalid > ... > > I am using Bison version 1.35 under Linux. The makefile converts the > yacc .y source file into .c with the following command and result. > > bison -y -d ibis-icm-yacc.y > conflicts: 32 shift/reduce, 10 reduce/reduce > > I can only presume your source has somehow become corrupted, or you are > possibly using an incompatible version of bison. > > Please ensure that you are using the correct archive. Archives were > provided for both windows (.zip), and unix (.tar) systems. They differ > in line termination sequences (cr/lf for windows, lf for unix), and may > not be processed properly if, for example, files from the windows > archive are processed under unix or vice-versa. > > Please also note: the Makefile post processes the bison output file to > produce the final ibis-icm-yacc.c file, so several more steps are > required if you are compiling by hand and not using Make. > > Since the ibis-icm-yacc.c output file is provided in the distribution, > it is not actually necessary to use bison on the source '.y' file at > all. You can simply compile the provided .c file. The use of bison is > required only if you must modify the original .y file. > > Finally, the syntax in question, '@$', is a location reference > (line/column) for the target of a rule, and is most assuredly a > legitimate construction. It should not cause bison to error out. > > If you have further questions, or additional information that might shed > some light on this problem, feel free to contact me, I will be happy to > help you sort out the problem. > > Regards - Kelly Green > > -- > Kelly Green <kgreen22@xxxxxxxxxxxxxx> ------------------------------------------------------------------ To unsubscribe from si-list: si-list-request@xxxxxxxxxxxxx with 'unsubscribe' in the Subject field or to administer your membership from a web page, go to: //www.freelists.org/webpage/si-list For help: si-list-request@xxxxxxxxxxxxx with 'help' in the Subject field List FAQ wiki page is located at: http://si-list.org/wiki/wiki.pl List technical documents are available at: http://www.si-list.org List archives are viewable at: //www.freelists.org/archives/si-list or at our remote archives: http://groups.yahoo.com/group/si-list/messages Old (prior to June 6, 2001) list archives are viewable at: http://www.qsl.net/wb6tpu