<div dir="ltr"><div>I believe the documentation is part of the body of the function. Maybe try node.Body.Documentation?<br><br></div>Stéphane<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, May 2, 2017 at 8:08 AM, Venkatesh Potluri <span dir="ltr"><<a href="mailto:venky.92@gmail.com" target="_blank">venky.92@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi list,<br>
<br>
I am unable to extract comments corresponding to a python function<br>
using IronPython in c#. Despite the python code corresponding to the<br>
FunctionDefinition node having comments, the FunctionDefinition<br>
node.documentation seems to be empty.<br>
<br>
What exactly am I missing?<br>
I am attaching my c# function override for Bool<br>
walk(FunctionDefinition node) and the python code I use for testing.<br>
<br>
// C# code:<br>
class MyWalker:PythonWalker {<br>
public override bool Walk(ClassDefinition node)<br>
{<br>
Trace.TraceInformation(node.<wbr>Documentation);<br>
return True;<br>
}<br>
}<br>
<br>
###Python Code that this is tested against:<br>
def printHello():<br>
"""This is a test DocString comment."""<br>
return 'hello'<br>
<br>
<br>
I do not get any output. the string is empty.<br>
<br>
Thank you and best regards,<br>
Venkatesh<br>
______________________________<wbr>_________________<br>
Ironpython-users mailing list<br>
<a href="mailto:Ironpython-users@python.org">Ironpython-users@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/ironpython-users" rel="noreferrer" target="_blank">https://mail.python.org/<wbr>mailman/listinfo/ironpython-<wbr>users</a><br>
</blockquote></div><br></div>