Skip to content
Permalink
Browse files

[sipify] fix annotations in multiline virtual methods

  • Loading branch information
3nids authored and nyalldawson committed Sep 14, 2018
1 parent 4cdf0a2 commit 05f35f2e19782b29efa8e2c50f37722986b02ee3
Showing with 3 additions and 3 deletions.
  1. +1 −1 python/core/auto_generated/qgsvectorlayer.sip.in
  2. +2 −2 scripts/sipify.pl
@@ -831,7 +831,7 @@ Load a named style from file/local db/datasource db
:param categories: the style categories to be loaded.
%End

virtual QString loadNamedStyle( const QString &theURI, bool &resultFlag SIP_OUT,
virtual QString loadNamedStyle( const QString &theURI, bool &resultFlag /Out/,
QgsMapLayer::StyleCategories categories = QgsMapLayer::AllStyleCategories );
%Docstring
Calls loadNamedStyle( theURI, resultFlag, false );
@@ -1042,7 +1042,7 @@ sub detect_non_method_member{
if ( $virtual_line !~ m/^(\s*)virtual\b(.*)$/ ){
my $idx = $#OUTPUT-$LINE_IDX+$virtual_line_idx+2;
#print "len: $#OUTPUT line_idx: $LINE_IDX virt: $virtual_line_idx\n"idx: $idx\n$OUTPUT[$idx]\n";
$OUTPUT[$idx] = $virtual_line =~ s/^(\s*?)\b(.*)$/$1 virtual $2\n/r;
$OUTPUT[$idx] = fix_annotations($virtual_line =~ s/^(\s*?)\b(.*)$/$1 virtual $2\n/r);
}
}
elsif ( $LINE !~ m/^(\s*)virtual\b(.*)$/ ){
@@ -1148,7 +1148,7 @@ sub detect_non_method_member{
}
}
elsif ( $LINE =~ m/^[^()]+\([^()]*([^()]*\([^()]*\)[^()]*)*[^)]*$/ ){
dbg_info("Mulitline detected");
dbg_info("Multiline detected:: $LINE");
if ( $LINE =~ m/^\s*((else )?if|while|for) *\(/ ){
$MULTILINE_DEFINITION = MULTILINE_CONDITIONAL_STATEMENT;
}

0 comments on commit 05f35f2

Please sign in to comment.
You can’t perform that action at this time.