lhs2tex
lhs2tex copied to clipboard
Preprocessor for typesetting Haskell sources with LaTeX
I just discovered that can use `\begin{code}...\end{code}` blocks in display math and even arrays, to format code blocks side-by-side: ```tex \[ \mathhs \begin{array}{ccc} \begin{code} not :: Bool -> Bool not...
Recent versions of acmart (at least since 1.70) cause an error with `\usepackage{amssymb}` (issue borisveytsman/acmart#395), which lhs2tex appears to insert unconditionally: https://github.com/kosmikus/lhs2tex/blob/34301bed0a895691631ab3acd61808411fae0711/lhs2TeX.sty.lit#L41 Example to reproduce: ``` % t.lhs \documentclass{acmart} %include...
lhs2TeX is a joy to use, as always, but I'm currently struggling with the following macro: ``` %if style == newcode %format (hat (a)) = "__hat" a %else %format (hat(a))...
For years I wondered why performance of the code generated by the `lhs2TeX` styling template I use (due to Richard Eisenberg) is so abyssmal when using `acmart`. It turns out...
Would it be possible to use the more precise `GPL-2.0-or-later` in the metadata? It would help the Nix folks: https://github.com/NixOS/nixpkgs/pull/269931#issuecomment-1826394776
Compiling the following code, ```latex \documentclass{article} %include lhs2TeX.fmt %include lhs2TeX.sty %include polycode.fmt %{ %format abs (a) = "\mathopen{|}" a "\mathclose{|}" \begin{document} \begin{code} abs(1) = abs(2) \end{code} \end{document} %} ``` with...
I use lhs2TeX for all my papers. It's wonderful. But it can't parse `'` in `Proxy :: Proxy 'True`! My solution has been to have `%format ! = "\mathop{}\tick"` but...
Using BlogLiteratelyD, one can embed a diagram created with the Haskell diagrams package (http://hackage.haskell.org/package/BlogLiterately-diagrams). Give we can \eval fragments of Haskell, it may not be too hard to generate diagrams...
cat > bug.lagda
Would it be possible to make identifiers produce links that point back to their definitions, so that the generated output is cross-referenced? I don't know if lhs2TeX actually parses the...