From 98784c59ab8b641c625e7d4c72275fd089f3ac3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hillerstr=C3=B6m?= Date: Fri, 17 Dec 2021 17:57:31 +0000 Subject: [PATCH] Section 2.3 --- thesis.tex | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/thesis.tex b/thesis.tex index c1af18d..508d939 100644 --- a/thesis.tex +++ b/thesis.tex @@ -3094,8 +3094,12 @@ The following handler implements the environment. The handler takes as input the current $user$ and a computation that may perform the $\Ask$ operation. When an invocation of $\Ask$ occurs the handler pattern matches on the $user$ parameter and resumes with a -string representation of the user. With this implementation we can -interpret an application of $\whoami$. +string representation of the user. This handler is an instance of a +so-called \emph{tail-resumptive} handler~\cite{Leijen17b,XieBHSL20} as +each resumption invocation appears in tail position within in the +operation clause. +% +With this implementation we can interpret an application of $\whoami$. % \[ \environment~\Record{\Root;\whoami} \reducesto^+ \strlit{root} : \String @@ -3105,8 +3109,8 @@ It is not difficult to extend this basic environment model to support an arbitrary number of variables. This can be done by parameterising the $\Ask$ operation by some name representation (e.g. a string), which the environment handler can use to index into a list of string -values. In case the name is unbound the environment, the handler can -embrace the laissez-faire attitude of \UNIX{} and resume with the +values. In case the name is not bound in the environment, the handler +can embrace the laissez-faire attitude of \UNIX{} and resume with the empty string. \paragraph{User session management}