git.iko.soy/typeable/pandoc
on 1.10.0.4 help sign in
typeable/pandoc/tests/lhs-test.latex
93 lines 3.3 kB history raw
1\documentclass[]{article}
2\usepackage[T1]{fontenc}
3\usepackage{lmodern}
4\usepackage{amssymb,amsmath}
5\usepackage{ifxetex,ifluatex}
6\usepackage{fixltx2e} % provides \textsubscript
7% use microtype if available
8\IfFileExists{microtype.sty}{\usepackage{microtype}}{}
9% use upquote if available, for straight quotes in verbatim environments
10\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
11\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
12 \usepackage[utf8]{inputenc}
13\else % if luatex or xelatex
14 \usepackage{fontspec}
15 \ifxetex
16 \usepackage{xltxtra,xunicode}
17 \fi
18 \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
19 \newcommand{\euro}{€}
20\fi
21\usepackage{color}
22\usepackage{fancyvrb}
23\DefineShortVerb[commandchars=\\\{\}]{\|}
24\DefineVerbatimEnvironment{Highlighting}{Verbatim}{commandchars=\\\{\}}
25% Add ',fontsize=\small' for more characters per line
26\newenvironment{Shaded}{}{}
27\newcommand{\KeywordTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{\textbf{{#1}}}}
28\newcommand{\DataTypeTok}[1]{\textcolor[rgb]{0.56,0.13,0.00}{{#1}}}
29\newcommand{\DecValTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
30\newcommand{\BaseNTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
31\newcommand{\FloatTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
32\newcommand{\CharTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
33\newcommand{\StringTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
34\newcommand{\CommentTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textit{{#1}}}}
35\newcommand{\OtherTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{{#1}}}
36\newcommand{\AlertTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
37\newcommand{\FunctionTok}[1]{\textcolor[rgb]{0.02,0.16,0.49}{{#1}}}
38\newcommand{\RegionMarkerTok}[1]{{#1}}
39\newcommand{\ErrorTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
40\newcommand{\NormalTok}[1]{{#1}}
41\ifxetex
42 \usepackage[setpagesize=false, % page size defined by xetex
43 unicode=false, % unicode breaks when used with xetex
44 xetex]{hyperref}
45\else
46 \usepackage[unicode=true]{hyperref}
47\fi
48\hypersetup{breaklinks=true,
49 bookmarks=true,
50 pdfauthor={},
51 pdftitle={},
52 colorlinks=true,
53 urlcolor=blue,
54 linkcolor=magenta,
55 pdfborder={0 0 0}}
56\setlength{\parindent}{0pt}
57\setlength{\parskip}{6pt plus 2pt minus 1pt}
58\setlength{\emergencystretch}{3em} % prevent overfull lines
59\setcounter{secnumdepth}{0}
61\author{}
62\date{}
64\begin{document}
66\section{lhs test}
68\texttt{unsplit} is an arrow that takes a pair of values and combines them to
69return a single value:
71\begin{Shaded}
72\begin{Highlighting}[]
73\OtherTok{unsplit ::} \NormalTok{(}\DataTypeTok{Arrow} \NormalTok{a) }\OtherTok{=>} \NormalTok{(b }\OtherTok{->} \NormalTok{c }\OtherTok{->} \NormalTok{d) }\OtherTok{->} \NormalTok{a (b, c) d}
74\NormalTok{unsplit }\FunctionTok{=} \NormalTok{arr }\FunctionTok{.} \FunctionTok{uncurry}
75 \CommentTok{-- arr (\textbackslash{}op (x,y) -> x `op` y) }
76\end{Highlighting}
77\end{Shaded}
79\texttt{(***)} combines two arrows into a new arrow by running the two arrows
80on a pair of values (one arrow on the first item of the pair and one arrow on
81the second item of the pair).
83\begin{verbatim}
84f *** g = first f >>> second g
85\end{verbatim}
87Block quote:
89\begin{quote}
90foo bar
91\end{quote}
93\end{document}