Welcome! Glad that you finally post it on utopian-io 😁. This is kind of tutorials that I'm waiting for (܍ ͜ʖ܍). Pretty much reminded me of EBNF and Earley parser. To make the tutorials category merrier, let me ask some questions related to Flex&Bison and also the way you write the tutorials 😉
- Is it possible to write a compiler which compiles our own syntax into shared lib which I can use in another programming language (via FFI maybe)
- Can I ask how do you put your code snippet in this post? I have a suspicion that this is a bug when someone copy-paste code from IDE into Markdown editor 🤔
- Lastly, I have been wondering what is yy stand for? 😂
Btw, have you played SHENZHEN I/O? What is your current level? 😋
Eager to wait for your next tutorial, especially a way to generate MIPS Assembly 😉
Normally the code snippet is something like this
variable: ID {printf("ID: %s\n", yylval.symtab_item->st_name);}| pointer ID | ID array ;
Not sure but seems like there are trailings zero width space in your code snippet 🤔
Hey! Nice to see from you again! :D
First of all, I'm a Computer Science Student studying for my first Bachelor's degree at the moment, meaning that the knowledge that I have is mostly around topics that we learn during that four years in my University. But, we tend to have lots of Hardware courses that got very in-depth into lots of things. Ase these courses are mandatory and not from a list of choices, many Students struggle with them. Either way, I'm currently entering the fourth and final year of my study. The Compiler Design class was in the first semester of the 3rd year.
I told you some things about my study so that you know how much validity you can expect from my information.
I would like to start by mentioning the following things:
After that answering your questions is now much easier I think. So, let's go:
I don't found time to play the Game in the Summer, as I tried to relax a little bit of University stuff by being full-time vacation ;) I know, I know I was still writing articles for Steemit, but these where about Physics that I enjoy a lot and also don't took so much time as this article for example. Now that you mention it again, I will try to play it in the following months to make a full review for it. I will inform you about my progress :P
Hmmm...generating MIPS assembly, I'm also not exactly sure how exactly I am supposed to do it right. :D I will just explain how exactly I did it and how it works for me, so that you can optimize it for any other language or better said AST on your own. I will give you an overall Idea of how we should do it and then give you Code for my specific Case :)
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit