Don't use missingIncludes
unless custom syntax defs have been given.
This avoids a huge performance sink that comes from evaluating all the elements of the default syntax map. Better just to have run-time errors for missing includes? See #4226.
This commit is contained in:
parent
0d935bd081
commit
3a22907306
1 changed files with 2 additions and 1 deletions
|
@ -268,7 +268,8 @@ convertWithOpts opts = do
|
|||
syntaxMap <- foldM addSyntaxMap defaultSyntaxMap
|
||||
(optSyntaxDefinitions opts)
|
||||
|
||||
case missingIncludes (M.elems syntaxMap) of
|
||||
unless (null (optSyntaxDefinitions opts)) $
|
||||
case missingIncludes (M.elems syntaxMap) of
|
||||
[] -> return ()
|
||||
xs -> E.throwIO $ PandocSyntaxMapError $
|
||||
"Missing syntax definitions:\n" ++
|
||||
|
|
Loading…
Add table
Reference in a new issue