1
0
forked from VimPlug/jedi

fake docstrs fixed

This commit is contained in:
Dave Halter
2014-02-26 02:38:28 +01:00
parent 44e16c11e5
commit acec5fe76f
2 changed files with 3 additions and 5 deletions

View File

@@ -103,10 +103,8 @@ def get_faked(module, obj, name=None):
if not isinstance(result, Class) and result is not None: if not isinstance(result, Class) and result is not None:
# Set the docstr which was previously not set (faked modules don't # Set the docstr which was previously not set (faked modules don't
# contain it). # contain it).
result.docstr = None doc = '''"""%s"""''' % obj.__doc__ # TODO need escapes.
if obj.__doc__: result.add_docstr(tokenize.Token(tokenize.STRING, doc, (0, 0)))
doc = '''"""%s"""''' % obj.__doc__ # TODO need escapes.
result.docstr = tokenize.Token(tokenize.STRING, doc, (0, 0))
return result return result

View File

@@ -182,7 +182,7 @@ class Simple(Base):
class IsScope(Base): class IsScope(Base):
pass __slots__ = ()
class Scope(Simple, IsScope, DocstringMixin): class Scope(Simple, IsScope, DocstringMixin):