git.iko.soy/typeable/pandoc
on 1.14.0.3 help sign in
typeable/pandoc/tests/lhs-test.latex
129 lines 5.1 kB history raw
1\documentclass[]{article}
2\usepackage{lmodern}
3\usepackage{amssymb,amsmath}
4\usepackage{ifxetex,ifluatex}
5\usepackage{fixltx2e} % provides \textsubscript
6\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
7 \usepackage[T1]{fontenc}
8 \usepackage[utf8]{inputenc}
9\else % if luatex or xelatex
10 \ifxetex
11 \usepackage{mathspec}
12 \usepackage{xltxtra,xunicode}
13 \else
14 \usepackage{fontspec}
15 \fi
16 \defaultfontfeatures{Mapping=tex-text,Scale=MatchLowercase}
17 \newcommand{\euro}{€}
18\fi
19% use upquote if available, for straight quotes in verbatim environments
20\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
21% use microtype if available
22\IfFileExists{microtype.sty}{%
23\usepackage{microtype}
24\UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
25}{}
26\ifxetex
27 \usepackage[setpagesize=false, % page size defined by xetex
28 unicode=false, % unicode breaks when used with xetex
29 xetex]{hyperref}
30\else
31 \usepackage[unicode=true]{hyperref}
32\fi
33\hypersetup{breaklinks=true,
34 bookmarks=true,
35 pdfauthor={},
36 pdftitle={},
37 colorlinks=true,
38 citecolor=blue,
39 urlcolor=blue,
40 linkcolor=magenta,
41 pdfborder={0 0 0}}
42\urlstyle{same} % don't use monospace font for urls
43\usepackage{color}
44\usepackage{fancyvrb}
45\newcommand{\VerbBar}{|}
46\newcommand{\VERB}{\Verb[commandchars=\\\{\}]}
47\DefineVerbatimEnvironment{Highlighting}{Verbatim}{commandchars=\\\{\}}
48% Add ',fontsize=\small' for more characters per line
49\newenvironment{Shaded}{}{}
50\newcommand{\KeywordTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{\textbf{{#1}}}}
51\newcommand{\DataTypeTok}[1]{\textcolor[rgb]{0.56,0.13,0.00}{{#1}}}
52\newcommand{\DecValTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
53\newcommand{\BaseNTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
54\newcommand{\FloatTok}[1]{\textcolor[rgb]{0.25,0.63,0.44}{{#1}}}
55\newcommand{\ConstantTok}[1]{\textcolor[rgb]{0.53,0.00,0.00}{{#1}}}
56\newcommand{\CharTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
57\newcommand{\SpecialCharTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
58\newcommand{\StringTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
59\newcommand{\VerbatimStringTok}[1]{\textcolor[rgb]{0.25,0.44,0.63}{{#1}}}
60\newcommand{\SpecialStringTok}[1]{\textcolor[rgb]{0.73,0.40,0.53}{{#1}}}
61\newcommand{\ImportTok}[1]{{#1}}
62\newcommand{\CommentTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textit{{#1}}}}
63\newcommand{\DocumentationTok}[1]{\textcolor[rgb]{0.73,0.13,0.13}{\textit{{#1}}}}
64\newcommand{\AnnotationTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textbf{\textit{{#1}}}}}
65\newcommand{\CommentVarTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textbf{\textit{{#1}}}}}
66\newcommand{\OtherTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{{#1}}}
67\newcommand{\FunctionTok}[1]{\textcolor[rgb]{0.02,0.16,0.49}{{#1}}}
68\newcommand{\VariableTok}[1]{\textcolor[rgb]{0.10,0.09,0.49}{{#1}}}
69\newcommand{\ControlFlowTok}[1]{\textcolor[rgb]{0.00,0.44,0.13}{\textbf{{#1}}}}
70\newcommand{\OperatorTok}[1]{\textcolor[rgb]{0.40,0.40,0.40}{{#1}}}
71\newcommand{\BuiltInTok}[1]{{#1}}
72\newcommand{\ExtensionTok}[1]{{#1}}
73\newcommand{\PreprocessorTok}[1]{\textcolor[rgb]{0.74,0.48,0.00}{{#1}}}
74\newcommand{\AttributeTok}[1]{\textcolor[rgb]{0.49,0.56,0.16}{{#1}}}
75\newcommand{\RegionMarkerTok}[1]{{#1}}
76\newcommand{\InformationTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textbf{\textit{{#1}}}}}
77\newcommand{\WarningTok}[1]{\textcolor[rgb]{0.38,0.63,0.69}{\textbf{\textit{{#1}}}}}
78\newcommand{\AlertTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
79\newcommand{\ErrorTok}[1]{\textcolor[rgb]{1.00,0.00,0.00}{\textbf{{#1}}}}
80\newcommand{\NormalTok}[1]{{#1}}
81\setlength{\parindent}{0pt}
82\setlength{\parskip}{6pt plus 2pt minus 1pt}
83\setlength{\emergencystretch}{3em} % prevent overfull lines
84\providecommand{\tightlist}{%
85 \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
86\setcounter{secnumdepth}{0}
88\date{}
90% Redefines (sub)paragraphs to behave more like sections
91\ifx\paragraph\undefined\else
92\let\oldparagraph\paragraph
93\renewcommand{\paragraph}[1]{\oldparagraph{#1}\mbox{}}
94\fi
95\ifx\subparagraph\undefined\else
96\let\oldsubparagraph\subparagraph
97\renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}}
98\fi
100\begin{document}
102\section{lhs test}\label{lhs-test}
104\texttt{unsplit} is an arrow that takes a pair of values and combines them to
105return a single value:
107\begin{Shaded}
108\begin{Highlighting}[]
109\OtherTok{unsplit ::} \NormalTok{(}\DataTypeTok{Arrow} \NormalTok{a) }\OtherTok{=>} \NormalTok{(b }\OtherTok{->} \NormalTok{c }\OtherTok{->} \NormalTok{d) }\OtherTok{->} \NormalTok{a (b, c) d}
110\NormalTok{unsplit }\FunctionTok{=} \NormalTok{arr }\FunctionTok{.} \NormalTok{uncurry}
111 \CommentTok{-- arr (\textbackslash{}op (x,y) -> x `op` y)}
112\end{Highlighting}
113\end{Shaded}
115\texttt{(***)} combines two arrows into a new arrow by running the two arrows
116on a pair of values (one arrow on the first item of the pair and one arrow on
117the second item of the pair).
119\begin{verbatim}
120f *** g = first f >>> second g
121\end{verbatim}
123Block quote:
125\begin{quote}
126foo bar
127\end{quote}
129\end{document}