Add intermezzo on wild binders.
authorMatthijs Kooijman <matthijs@stdin.nl>
Mon, 7 Dec 2009 10:53:09 +0000 (11:53 +0100)
committerMatthijs Kooijman <matthijs@stdin.nl>
Mon, 7 Dec 2009 10:53:09 +0000 (11:53 +0100)
Chapters/Normalization.tex

index 4eb9c62b2b3c2af966c23da337628828e36d6a7c..b058b63a2a3debae92f4fe435fe1f31799555c40 100644 (file)
         \transexample{letflat}{Case normalisation}{from}{to}
 
 
         \transexample{letflat}{Case normalisation}{from}{to}
 
 
+        \placeintermezzo{}{
+          \defref{wild binders}
+          \startframedtext[width=7cm,background=box,frame=no]
+          \startalignment[center]
+            {\tfa Wild binders}
+          \stopalignment
+          \blank[medium]
+            In a functional expression, a \emph{wild binder} refers to any
+            binder that is never referenced. This means that even though it
+            will be bound to a particular value, that value is never used.
+
+            The Haskell syntax offers the underscore as a wild binder that
+            cannot even be referenced (It can be seen as introducing a new,
+            anonymous, binder everytime it is used).
+            
+            In these transformations, the term wild binder will sometimes be
+            used to indicate that a binder must not be referenced.
+          \stopframedtext
+        }
+
       \subsubsection{Case normalization}
         This transformation ensures that all case expressions get a form
         that is allowed by the intended normal form. This means they
       \subsubsection{Case normalization}
         This transformation ensures that all case expressions get a form
         that is allowed by the intended normal form. This means they
-        will become one of: \refdef{intended normal form definition}
+        will become one of:
 
         \startitemize
         \item An extractor case with a single alternative that picks a field
 
         \startitemize
         \item An extractor case with a single alternative that picks a field
             Cn wn,0 ... wn,m -> yn
         \stoptrans
 
             Cn wn,0 ... wn,m -> yn
         \stoptrans
 
-        \refdef{wild binder}
         Note that this transformation applies to case expressions with any
         scrutinee. If the scrutinee is a complex expression, this might
         result in duplication of work (hardware). An extra condition to
         Note that this transformation applies to case expressions with any
         scrutinee. If the scrutinee is a complex expression, this might
         result in duplication of work (hardware). An extra condition to