git.iko.soy/typeable/pandoc
on rc/2.11.0.3 help sign in
typeable/pandoc/test/lhs-test.latex+lhs
87 lines 2.6 kB history raw
1% Options for packages loaded elsewhere
2\PassOptionsToPackage{unicode}{hyperref}
3\PassOptionsToPackage{hyphens}{url}
4%
5\documentclass[
6]{article}
7\usepackage{lmodern}
8\usepackage{amsmath}
9\usepackage{ifxetex,ifluatex}
10\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex
11 \usepackage[T1]{fontenc}
12 \usepackage[utf8]{inputenc}
13 \usepackage{textcomp} % provide euro and other symbols
14 \usepackage{amssymb}
15\else % if luatex or xetex
16 \usepackage{unicode-math}
17 \defaultfontfeatures{Scale=MatchLowercase}
18 \defaultfontfeatures[\rmfamily]{Ligatures=TeX,Scale=1}
19\fi
20% Use upquote if available, for straight quotes in verbatim environments
21\IfFileExists{upquote.sty}{\usepackage{upquote}}{}
22\IfFileExists{microtype.sty}{% use microtype if available
23 \usepackage[]{microtype}
24 \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts
25}{}
26\makeatletter
27\@ifundefined{KOMAClassName}{% if non-KOMA class
28 \IfFileExists{parskip.sty}{%
29 \usepackage{parskip}
30 }{% else
31 \setlength{\parindent}{0pt}
32 \setlength{\parskip}{6pt plus 2pt minus 1pt}}
33}{% if KOMA class
34 \KOMAoptions{parskip=half}}
35\makeatother
36\usepackage{xcolor}
37\IfFileExists{xurl.sty}{\usepackage{xurl}}{} % add URL line breaks if available
38\IfFileExists{bookmark.sty}{\usepackage{bookmark}}{\usepackage{hyperref}}
39\hypersetup{
40 hidelinks,
41 pdfcreator={LaTeX via pandoc}}
42\urlstyle{same} % disable monospaced font for URLs
43\usepackage{listings}
44\newcommand{\passthrough}[1]{#1}
45\lstset{defaultdialect=[5.3]Lua}
46\lstset{defaultdialect=[x86masm]Assembler}
47\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{}
48\setlength{\emergencystretch}{3em} % prevent overfull lines
49\providecommand{\tightlist}{%
50 \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
51\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
52\ifluatex
53 \usepackage{selnolig} % disable illegal ligatures
54\fi
56\author{}
57\date{}
59\begin{document}
61\hypertarget{lhs-test}{%
62\section{lhs test}\label{lhs-test}}
64\texttt{unsplit} is an arrow that takes a pair of values and combines them to
65return a single value:
67\begin{code}
68unsplit :: (Arrow a) => (b -> c -> d) -> a (b, c) d
69unsplit = arr . uncurry
70 -- arr (\op (x,y) -> x `op` y)
71\end{code}
73\texttt{(***)} combines two arrows into a new arrow by running the two arrows on a
74pair of values (one arrow on the first item of the pair and one arrow on the
75second item of the pair).
77\begin{verbatim}
78f *** g = first f >>> second g
79\end{verbatim}
81Block quote:
83\begin{quote}
84foo bar
85\end{quote}
87\end{document}