我对此没有任何想法。请看最简单的例子。
\documentclass[draft]{book}
\usepackage[utf8]{inputenc}
\usepackage[T2A]{fontenc}
\usepackage[russian]{babel}
\usepackage [
style = gost-numeric,
backend = biber,
language = auto
]{biblatex}
\addbibresource{ref.bib}
\begin{document}
\cite[{АБВГДЕЁЖЗИЙКЛМНПРСТУФХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.
\printbibliography
\end{document}
ref.bib
:
@ARTICLE{A,
author = {author},
title = {title},
journal = {journal},
year = {2000},
volume = {1},
pages = {1--100}
}
输出:
Errors:
.../minimal.tex:18: Missing ) inserted for expression. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing = inserted for \ifnum. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing number, treated as zero. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing ) inserted for expression. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing number, treated as zero. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing ) inserted for expression. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing = inserted for \ifnum. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing number, treated as zero. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing ) inserted for expression. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing = inserted for \ifnum. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
.../minimal.tex:18: Missing number, treated as zero. [...ХЦЧШЩЪЫЬЭЮЯ О}~1234567890]{A}.]
有完整的俄文字母,但只有“О”会出现问题。删除“О”则不会出现“错误”。
有人知道是什么问题吗?
答案1
这似乎是 中的一个错误\blx@imc@ifnumeral
,因为该行为可以通过以下方式重现:
\documentclass{article}
\usepackage[utf8]{inputenc}
\usepackage[T2A]{fontenc}
\usepackage[russian]{babel}
\usepackage{biblatex}
\begin{document}
\makeatletter
%\blx@imc@ifnumeral{Н}{\typeout{numeral}}{\typeout{not numeral}}
\blx@imc@ifnumeral{О}{\typeout{numeral}}{\typeout{not numeral}}
%\blx@imc@ifnumeral{П}{\typeout{numeral}}{\typeout{not numeral}}
%\blx@imc@ifnumeral{н}{\typeout{numeral}}{\typeout{not numeral}}
%\blx@imc@ifnumeral{о}{\typeout{numeral}}{\typeout{not numeral}}
%\blx@imc@ifnumeral{п}{\typeout{numeral}}{\typeout{not numeral}}
\makeatother
\end{document}
注释掉的行不会触发错误。请参见https://github.com/plk/biblatex/issues/559提交一份报告。
你可以用一个临时解决方案来“修复”这个问题:使用
\CYRO
而不是西里尔字母О
(U+041E 西里尔大写字母 O)。
\begin{filecontents*}{\jobname.bib}
@ARTICLE{A,
author = {author},
title = {title},
journal = {journal},
year = {2000},
volume = {1},
pages = {1--100}
}
\end{filecontents*}
\documentclass{book}
\usepackage[utf8]{inputenc}
\usepackage[T2A]{fontenc}
\usepackage[russian]{babel}
\usepackage{csquotes}
\usepackage [
style = gost-numeric,
backend = biber,
language = auto
]{biblatex}
\addbibresource{\jobname.bib}
\begin{document}
\cite[АБВГДЕЁЖЗИЙКЛМНП\CYRO РСТУФХЦЧШЩЪЫЬЭЮЯ~1234567890]{A}.
\printbibliography
\end{document}