a newbie's dumb question...

explosion78@hotmail.com (Sunny)
18 Jul 2001 19:59:20 -0400

          From comp.compilers

Related articles
a newbie's dumb question... explosion78@hotmail.com (2001-07-18)
Re: a newbie's dumb question... kvinay@ip.eth.net (Vinay Kakade) (2001-07-23)
Re: a newbie's dumb question... joachim_d@gmx.de (Joachim Durchholz) (2001-07-23)
Re: a newbie's dumb question... haberg@matematik.su.se (2001-07-23)
Re: a newbie's dumb question... hirner@yahoo.com (ThaFacka) (2001-07-23)
Re: a newbie's dumb question... rkrayhawk@aol.com (2001-07-27)
Re: a newbie's dumb question... james.grosbach@microchip.com (James Grosbach) (2001-07-30)
| List of all articles for this month |

From: explosion78@hotmail.com (Sunny)
Newsgroups: comp.compilers
Date: 18 Jul 2001 19:59:20 -0400
Organization: http://groups.google.com/
Keywords: question
Posted-Date: 18 Jul 2001 19:59:20 EDT

Hi there~!


I just strated to use lex and yacc to make a compiler for PICmicro
assembler. I have gathered enough materials for lex and yacc over the
internet. But I still don't have a slight idea of making a compiler
though. I've sort of done the lex part, creating token and stuff. But
I can't do the yacc part yet.


A friend of mine has done it for 68HC11. His compiler reads the whole
code first and stack it, then finds any errors. Is it a good way? Or
is there another way??


And the errors.. I spent a lot of hours to seek any clues about
error-checking. I found one compiler which had over 200 error
messages... I can only think of branch range errors, labeling errors
and nothing else. Can any of you give me some ideas??


Finally, parsers. I sort of understand that it's hierarchical and it
eventually comes down to the token that the lex makes. Is that all
there is to it? So am I just need to find the types of grammars (eg
opcode label, label opcode number)??




I know it's really basic and kind of dumb to ask these questions. But
please give me some hints or anything..




Thanks~!


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.