forked from VimPlug/jedi
Remove google docstrings support. Updates #40
This commit is contained in:
@@ -8,17 +8,11 @@ import parsing
|
|||||||
DOCSTRING_PARAM_PATTERNS = [
|
DOCSTRING_PARAM_PATTERNS = [
|
||||||
r'\s*:type\s+%s:\s*([^\n]+)', # Sphinx
|
r'\s*:type\s+%s:\s*([^\n]+)', # Sphinx
|
||||||
r'\s*@type\s+%s:\s*([^\n]+)', # Epidoc
|
r'\s*@type\s+%s:\s*([^\n]+)', # Epidoc
|
||||||
r'\s*%s\s+\(([^()]+)\)' # googley
|
|
||||||
]
|
]
|
||||||
|
|
||||||
DOCSTRING_RETURN_PATTERNS = [
|
DOCSTRING_RETURN_PATTERNS = [
|
||||||
re.compile(r'\s*:rtype:\s*([^\n]+)', re.M), # Sphinx
|
re.compile(r'\s*:rtype:\s*([^\n]+)', re.M), # Sphinx
|
||||||
re.compile(r'\s*@rtype:\s*([^\n]+)', re.M), # Epidoc
|
re.compile(r'\s*@rtype:\s*([^\n]+)', re.M), # Epidoc
|
||||||
|
|
||||||
# Googley is the most undocumented format for
|
|
||||||
# return types, so we try to analyze the first
|
|
||||||
# line or line after `Returns:` keyword
|
|
||||||
re.compile(r'returns\s*:[\s\n]*([^\n]+)', re.M|re.I),
|
|
||||||
]
|
]
|
||||||
|
|
||||||
#@cache.memoize_default() # TODO add
|
#@cache.memoize_default() # TODO add
|
||||||
|
|||||||
@@ -17,22 +17,6 @@ def f(a, b):
|
|||||||
#? dict()
|
#? dict()
|
||||||
f()
|
f()
|
||||||
|
|
||||||
def g(a, b):
|
|
||||||
""" asdfasdf
|
|
||||||
Arguments:
|
|
||||||
a (str): blablabla
|
|
||||||
|
|
||||||
Returns: list
|
|
||||||
Blah blah.
|
|
||||||
"""
|
|
||||||
#? str()
|
|
||||||
a
|
|
||||||
#?
|
|
||||||
b
|
|
||||||
|
|
||||||
#? list()
|
|
||||||
g()
|
|
||||||
|
|
||||||
def e(a, b):
|
def e(a, b):
|
||||||
""" asdfasdf
|
""" asdfasdf
|
||||||
@type a: str
|
@type a: str
|
||||||
|
|||||||
@@ -83,7 +83,10 @@ row = c.fetchall()[0]
|
|||||||
row.keys()[0]
|
row.keys()[0]
|
||||||
|
|
||||||
def huhu(db):
|
def huhu(db):
|
||||||
"""db (sqlite3.Connection): the db connection"""
|
"""
|
||||||
|
:type db: sqlite3.Connection
|
||||||
|
:param db: the db connection
|
||||||
|
"""
|
||||||
#? sqlite3.Connection()
|
#? sqlite3.Connection()
|
||||||
db
|
db
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user