summaryrefslogtreecommitdiff
path: root/Documentation/sphinx
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2016-06-01 11:12:42 +0200
committerJani Nikula <jani.nikula@intel.com>2016-06-01 12:28:31 +0300
commit9cc1a44c03113cb2f3be73650d7c611c3e273ada (patch)
tree954538e4cdbf2285107656ec5503bfd93f83841c /Documentation/sphinx
parentba35018593547eac69998e2571fc95cf620f2220 (diff)
doc/sphinx: Pass right filename as source
With this error output becomes almost readable. The line numbers are still totally bonghits, but that's a lot harder to pull out of kerneldoc. We'd essentially have to insert some special markers in the kernel-doc output, split the output along these markers and then insert each block separately using state_machine.insert_input(block, source, first_line) Cc: Jani Nikula <jani.nikula@intel.com> Cc: linux-doc@vger.kernel.org Cc: Jonathan Corbet <corbet@lwn.net> Signed-off-by: Daniel Vetter <daniel.vetter@intel.com> Signed-off-by: Jani Nikula <jani.nikula@intel.com>
Diffstat (limited to 'Documentation/sphinx')
-rw-r--r--Documentation/sphinx/kernel-doc.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Documentation/sphinx/kernel-doc.py b/Documentation/sphinx/kernel-doc.py
index a6e170872c8a..9fc2c27916a9 100644
--- a/Documentation/sphinx/kernel-doc.py
+++ b/Documentation/sphinx/kernel-doc.py
@@ -57,7 +57,7 @@ class KernelDocDirective(Directive):
env.note_dependency(os.path.abspath(filename))
tab_width = self.options.get('tab-width', self.state.document.settings.tab_width)
- source = self.state_machine.input_lines.source(self.lineno - self.state_machine.input_offset - 1)
+ source = filename
# FIXME: make this nicer and more robust against errors
if 'export' in self.options: