kosmikus / lhs2tex

Preprocessor for typesetting Haskell sources with LaTeX
Other
99 stars 28 forks source link

Use the correct filepaths in preprocessor mode #80

Closed mpickering closed 4 years ago

mpickering commented 4 years ago

In the preprocessor mode GHC passes three filepaths in the following form

-h fp infile outfile

The -h argument is intended to be used in the LINE pragma, and the input should be read from the input file and written to the output file.

lhs2tex was reading the contents of fp and using that rather than the infile argument which was only noticed when using lhs2tex as a preprocessor with ghcide.

kosmikus commented 4 years ago

Looks great. Thanks!