Open hendychua opened 2 years ago
Hi there,
I would like to get the line number of the end of a function definition. Is there a way to do this?
To give an example, suppose the source code is:
def Foo(x): # line 1 if x == 42: return True else: return False # line 5
The parsed output would return where the function definition completes, i.e. line 5.
Currently, span.end seems to point to where the symbol name definition ends but not where the whole function ends:
span.end
{ "symbol": "Foo", "kind": "Function", "line": "def Foo(x):", "span": { "start": { "line": 1, "column": 5 }, "end": { "line": 1, "column": 8 } }, "nodeType": "DEFINITION" },
Thank you.
Hi there,
I would like to get the line number of the end of a function definition. Is there a way to do this?
To give an example, suppose the source code is:
The parsed output would return where the function definition completes, i.e. line 5.
Currently,
span.end
seems to point to where the symbol name definition ends but not where the whole function ends:Thank you.