Skip to content

Fix for pandoc-3.8#709

Closed
hololeap wants to merge 2 commits into
jgm:masterfrom
hololeap:master
Closed

Fix for pandoc-3.8#709
hololeap wants to merge 2 commits into
jgm:masterfrom
hololeap:master

Conversation

@hololeap

Copy link
Copy Markdown
Contributor

Currently, building gitit with pandoc-3.8 fails with:

[12 of 21] Compiling Network.Gitit.ContentTransformer ( src/Network/Gitit/ContentTransformer.hs, dist/build/Network/Gitit/ContentTransformer.o, dist/build/Network/Gitit/ContentTransformer.dyn_o )

src/Network/Gitit/ContentTransformer.hs:523:25: error: [GHC-22385]
    Not in scope: record field ‘writerHighlightStyle’
    Suggested fix:
      Perhaps use record field of WriterOptions ‘writerHighlightMethod’ (imported from Text.Pandoc)
    |
523 |                       , writerHighlightStyle = Just pygments
    |                         ^^^^^^^^^^^^^^^^^^^^

But, it is an easy fix.

Signed-off-by: hololeap <hololeap@protonmail.com>
Signed-off-by: hololeap <hololeap@protonmail.com>
@jgm

jgm commented Oct 14, 2025

Copy link
Copy Markdown
Owner

This won't work for multiple pandoc versions unless you use CPP conditions in the code, so that the old API will be used for older pandoc versions.

#if MIN_VERSION_pandoc(3,8,0)

#else 

#endif

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants