Skip to content

Commit

Permalink
[sipify] avoid printing empty Docstrings
Browse files Browse the repository at this point in the history
  • Loading branch information
3nids committed Dec 16, 2017
1 parent 60e9b26 commit 8db419c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/sipify.pl
Expand Up @@ -947,8 +947,8 @@ sub detect_comment_block{
}
else {
dbg_info('writing comment');
write_output("CM1", "%Docstring\n");
if ( $COMMENT !~ m/^\s*$/ ){
write_output("CM1", "%Docstring\n");
my @comment_lines = split /\n/, $COMMENT;
foreach my $comment_line (@comment_lines) {
# if ( $RETURN_TYPE ne '' && $comment_line =~ m/^\s*\.\. \w/ ){
Expand All @@ -963,11 +963,11 @@ sub detect_comment_block{
# $RETURN_TYPE = '';
# }
}
write_output("CM4", "%End\n");
}
# if ( $RETURN_TYPE ne '' ){
# write_output("CM3", "\n:rtype: $RETURN_TYPE\n");
# }
write_output("CM4", "%End\n");
}
$COMMENT = '';
$RETURN_TYPE = '';
Expand Down

0 comments on commit 8db419c

Please sign in to comment.