summaryrefslogtreecommitdiff
path: root/sphinx/writers/texinfo.py
diff options
context:
space:
mode:
authorYves Chevallier <yves-chevallier@heig-vd.ch>2020-08-12 16:29:26 +0200
committerYves Chevallier <yves-chevallier@heig-vd.ch>2020-08-12 16:29:26 +0200
commit53a82a56303ae2e0be1e5613db0da3611b1aabb1 (patch)
tree417b9a88851d9e2a7c36fbf0e88f99f97340b75a /sphinx/writers/texinfo.py
parent38b868cc0d0583d9a58496cd121f0bc345bf9eaa (diff)
downloadsphinx-git-53a82a56303ae2e0be1e5613db0da3611b1aabb1.tar.gz
Use node as location
Diffstat (limited to 'sphinx/writers/texinfo.py')
-rw-r--r--sphinx/writers/texinfo.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/sphinx/writers/texinfo.py b/sphinx/writers/texinfo.py
index 8c52a0868..5ad2831dd 100644
--- a/sphinx/writers/texinfo.py
+++ b/sphinx/writers/texinfo.py
@@ -628,7 +628,7 @@ class TexinfoTranslator(SphinxTranslator):
elif not isinstance(parent, nodes.section):
logger.warning(__('encountered title node not in section, topic, table, '
'admonition or sidebar'),
- location=(self.curfilestack[-1], node.line))
+ location=node)
self.visit_rubric(node)
else:
try:
@@ -1186,7 +1186,7 @@ class TexinfoTranslator(SphinxTranslator):
self.body.append('\n@caption{')
else:
logger.warning(__('caption not inside a figure.'),
- location=(self.curfilestack[-1], node.line))
+ location=node)
def depart_caption(self, node: Element) -> None:
if (isinstance(node.parent, nodes.figure) or
@@ -1262,11 +1262,11 @@ class TexinfoTranslator(SphinxTranslator):
def unimplemented_visit(self, node: Element) -> None:
logger.warning(__("unimplemented node type: %r"), node,
- location=(self.curfilestack[-1], node.line))
+ location=node)
def unknown_visit(self, node: Node) -> None:
logger.warning(__("unknown node type: %r"), node,
- location=(self.curfilestack[-1], node.line))
+ location=node)
def unknown_departure(self, node: Node) -> None:
pass