summaryrefslogtreecommitdiff
path: root/rulesquotify.tex
diff options
context:
space:
mode:
Diffstat (limited to 'rulesquotify.tex')
-rw-r--r--rulesquotify.tex23
1 files changed, 23 insertions, 0 deletions
diff --git a/rulesquotify.tex b/rulesquotify.tex
index 50acc22..0c0f09c 100644
--- a/rulesquotify.tex
+++ b/rulesquotify.tex
@@ -12,6 +12,29 @@ q - "Quotifies" the string on top of the stack, so that it can be placed
Er worden dus quotes om de string heen gezet. Als er in de oorspronkelijke string quotes stonden dan wordt voor iedere van deze quotes een "$\backslash$" geplaats.
+Om de backslashes te zetten word gebruik gemaakt van de hulpfunctie quo
Dit geeft de volgende regel:
+$$
+\begin{prooftree}
+ \trans
+ {\pgm}{\ip}{(\push{"quo (c s)"}{\stk'}, \str) }
+ {\ip}{\op}{\st}
+ \justifies
+ \trans
+ {\StmQuotify:\pgm}{\ip}{(\stk,\str)}
+ {\ip}{\op}{\st}
+ \using{\rquotifyns}
+ \qquad
+ \text{met (c s, stk') = pop (stk)
+ }
+\end{prooftree}
+$$
+$$
+ \quo {c} {s} =
+ \begin{cases}
+ \texttt{" c quo s} & \text{als $c=\texttt{"}$} \\
+ \texttt{c quo s} & \text{anderszins}
+ \end{cases}
+$$ \ No newline at end of file