mirror of
https://github.com/davidhalter/jedi.git
synced 2025-12-07 22:44:27 +08:00
showing pydoc with VIM plugin
This commit is contained in:
@@ -121,6 +121,14 @@ class Definition(object):
|
||||
d = d.get_code().replace('\n', '')
|
||||
return d
|
||||
|
||||
@property
|
||||
def doc(self):
|
||||
try:
|
||||
return str(self.definition.docstr)
|
||||
except AttributeError:
|
||||
return ''
|
||||
|
||||
|
||||
def __str__(self):
|
||||
if self.module_path[0] == os.path.sep:
|
||||
position = '@%s' % (self.line_nr)
|
||||
|
||||
Reference in New Issue
Block a user