mirror of
https://github.com/jgm/pandoc.git
synced 2026-08-25 17:56:32 +00:00
Set proper initial source name in parsing BibTeX.
(For better error messages.)
This commit is contained in:
@@ -71,9 +71,11 @@ readBibtexString variant locale idpred contents = do
|
||||
filter (\item -> idpred (identifier item) &&
|
||||
entryType item /= "xdata"))
|
||||
(fromMaybe defaultLang $ localeLanguage locale, Map.empty)
|
||||
"" (toSources contents) of
|
||||
(initialSourceName sources) sources of
|
||||
Left err -> Left err
|
||||
Right xs -> return xs
|
||||
where
|
||||
sources = toSources contents
|
||||
|
||||
-- | Write BibTeX or BibLaTeX given given a 'Reference'.
|
||||
writeBibtexString :: WriterOptions -- ^ options (for writing LaTex)
|
||||
|
||||
Reference in New Issue
Block a user