Fix #7701: LaTeX: Anonymous indirect target causes duplicated labels

This commit is contained in:
Takeshi KOMIYA 2020-05-23 22:55:24 +09:00
parent a1293e2825
commit 638b197d25
2 changed files with 3 additions and 0 deletions

View File

@ -117,6 +117,7 @@ Bugs fixed
supporting images
* #7610: incorrectly renders consecutive backslashes for docutils-0.16
* #7646: handle errors on event handlers
* #7701: LaTeX: Anonymous indirect hyperlink target causes duplicated labels
* C++, fix rendering and xrefs in nested names explicitly starting
in global scope, e.g., ``::A::B``.
* C, fix rendering and xrefs in nested names explicitly starting

View File

@ -1431,6 +1431,8 @@ class LaTeXTranslator(SphinxTranslator):
if 'refuri' in node:
return
if 'anonymous' in node:
return
if node.get('refid'):
prev_node = get_prev_node(node)
if isinstance(prev_node, nodes.reference) and node['refid'] == prev_node['refid']: