How to create Lr(1) parser for very simple programming language

732 Views Asked by At

I need to create the parser for code with variables, simple conditions, cycles and functions, something like:

f=1;
i=1;
while(i<10){
  f=f*i;
  i=i+1;
}
print(f);

I read a lot of theory, but I didn't find any working example of Lr(1) Parser for code. It's necessary to do it without any parser generators.. Anybody?

0

There are 0 best solutions below