emitDoc method
Emits the Python documentation for this entry.
Implementation
@override
void emitDoc(StringBuffer buffer) {
try {
final String? doc = inspectModule.getdoc(source.value)?.trim();
if (doc == null) {
return;
}
if (doc.isEmpty) {
return;
}
buffer.writeln("""
///
/// ### python docstring
///""");
for (final String line in doc.split("\n")) {
buffer.writeln("/// $line");
}
} on PythonFfiException catch (_) {
// ignore
}
}