X-Git-Url: https://ruin.nu/git/?p=proglang.git;a=blobdiff_plain;f=Docsyntax.tex;h=a4040dc8da604ba2614e495033c45b9c03029ef7;hp=b22e5448befef0133379770c9d9808a2e2ed5178;hb=33370917adde77f98b0955843b3222d9838a3fe8;hpb=b33c4977fff6bad375551eaf4fed0aa06daf1c88 diff --git a/Docsyntax.tex b/Docsyntax.tex index b22e544..a4040dc 100644 --- a/Docsyntax.tex +++ b/Docsyntax.tex @@ -80,11 +80,11 @@ All other symbols are terminals.\\ & {\delimit} &{\terminal{if}} {\terminal{(}} {\nonterminal{Exp}} {\terminal{)}} {\nonterminal{Stm}} {\terminal{else}} {\nonterminal{Stm}} \\ & {\delimit} &{\terminal{while}} {\terminal{(}} {\nonterminal{Exp}} {\terminal{)}} {\nonterminal{Stm}} \\ & {\delimit} &{\terminal{print}} {\nonterminal{Exp}} {\terminal{;}} \\ - & {\delimit} &{\nonterminal{Stm}} {\terminal{;}} \\ \end{tabular}\\ \begin{tabular}{lll} {\nonterminal{Exp}} & {\arrow} &{\nonterminal{Exp1}} {\nonterminal{BOp}} {\nonterminal{Exp1}} \\ + & {\delimit} &{\nonterminal{Ident}} {\terminal{{$=$}}} {\nonterminal{Exp}} \\ & {\delimit} &{\nonterminal{Exp1}} \\ \end{tabular}\\ @@ -102,13 +102,16 @@ All other symbols are terminals.\\ {\nonterminal{Exp3}} & {\arrow} &{\nonterminal{Ident}} {\terminal{{$+$}{$+$}}} \\ & {\delimit} &{\nonterminal{Ident}} {\terminal{{$-$}{$-$}}} \\ & {\delimit} &{\nonterminal{Ident}} \\ - & {\delimit} &{\nonterminal{Ident}} {\terminal{{$=$}}} {\nonterminal{Exp}} \\ & {\delimit} &{\nonterminal{Integer}} \\ & {\delimit} &{\terminal{{$-$}}} {\nonterminal{Exp3}} \\ & {\delimit} &{\nonterminal{Bool}} \\ & {\delimit} &{\terminal{readInt}} \\ & {\delimit} &{\terminal{readBool}} \\ - & {\delimit} &{\terminal{(}} {\nonterminal{Exp}} {\terminal{)}} \\ + & {\delimit} &{\nonterminal{Exp4}} \\ +\end{tabular}\\ + +\begin{tabular}{lll} +{\nonterminal{Exp4}} & {\arrow} &{\terminal{(}} {\nonterminal{Exp}} {\terminal{)}} \\ \end{tabular}\\ \begin{tabular}{lll}