equal
deleted
inserted
replaced
599 |
599 |
600 text {* |
600 text {* |
601 \noindent This maps to Haskell as follows: |
601 \noindent This maps to Haskell as follows: |
602 *} |
602 *} |
603 (*<*)code_include %invisible Haskell "Natural" -(*>*) |
603 (*<*)code_include %invisible Haskell "Natural" -(*>*) |
604 text %quote {* |
604 text %quote %typewriter {* |
605 \begin{typewriter} |
605 @{code_stmts example (Haskell)} |
606 @{code_stmts example (Haskell)} |
|
607 \end{typewriter} |
|
608 *} |
606 *} |
609 |
607 |
610 text {* |
608 text {* |
611 \noindent The code in SML has explicit dictionary passing: |
609 \noindent The code in SML has explicit dictionary passing: |
612 *} |
610 *} |
613 text %quote {* |
611 text %quote %typewriter {* |
614 \begin{typewriter} |
612 @{code_stmts example (SML)} |
615 @{code_stmts example (SML)} |
|
616 \end{typewriter} |
|
617 *} |
613 *} |
618 |
614 |
619 |
615 |
620 text {* |
616 text {* |
621 \noindent In Scala, implicts are used as dictionaries: |
617 \noindent In Scala, implicts are used as dictionaries: |
622 *} |
618 *} |
623 (*<*)code_include %invisible Scala "Natural" -(*>*) |
619 (*<*)code_include %invisible Scala "Natural" -(*>*) |
624 text %quote {* |
620 text %quote %typewriter {* |
625 \begin{typewriter} |
621 @{code_stmts example (Scala)} |
626 @{code_stmts example (Scala)} |
|
627 \end{typewriter} |
|
628 *} |
622 *} |
629 |
623 |
630 |
624 |
631 subsection {* Inspecting the type class universe *} |
625 subsection {* Inspecting the type class universe *} |
632 |
626 |