mirror of
https://github.com/qgis/QGIS.git
synced 2025-04-15 00:04:00 -04:00
followup b46de90d53c9298ba4f1267d2bdabcf4d669afe5
This commit is contained in:
parent
7f3941e073
commit
5e220e69ec
@ -569,9 +569,11 @@ while ($line_idx < $line_count){
|
|||||||
$line =~ s/SIP_PYNAME\(\s*(\w+)\s*\)/\/PyName=$1\//;
|
$line =~ s/SIP_PYNAME\(\s*(\w+)\s*\)/\/PyName=$1\//;
|
||||||
|
|
||||||
# combine multiple annotations
|
# combine multiple annotations
|
||||||
dbg_info("combine multiple annotations -- works only for 2");
|
|
||||||
# https://regex101.com/r/uvCt4M/1
|
# https://regex101.com/r/uvCt4M/1
|
||||||
$line =~ s/\/(\w+(=\w+)?)\/\s*\/(\w+(=\w+)?)\/\s*;(\s*(\/\/.*)?)$/\/$1,$3\/$5;/;
|
do {no warnings 'uninitialized';
|
||||||
|
$line =~ s/\/(\w+(=\w+)?)\/\s*\/(\w+(=\w+)?)\/\s*;(\s*(\/\/.*)?)$/\/$1,$3\/$5;/;
|
||||||
|
($3 == undef) or dbg_info("combine multiple annotations -- works only for 2");
|
||||||
|
};
|
||||||
|
|
||||||
# unprinted annotations
|
# unprinted annotations
|
||||||
$line =~ s/(\w+)(\<(?>[^<>]|(?2))*\>)?\s+SIP_PYARGTYPE\(\s*\'?([^()']+)(\(\s*(?:[^()]++|(?2))*\s*\))?\'?\s*\)/$3/g;
|
$line =~ s/(\w+)(\<(?>[^<>]|(?2))*\>)?\s+SIP_PYARGTYPE\(\s*\'?([^()']+)(\(\s*(?:[^()]++|(?2))*\s*\))?\'?\s*\)/$3/g;
|
||||||
@ -657,7 +659,9 @@ while ($line_idx < $line_count){
|
|||||||
next;
|
next;
|
||||||
}
|
}
|
||||||
elsif ( $line =~ m/\/\// || $line =~ m/\s*typedef / || $line =~ m/\s*struct / || $line =~ m/operator\[\]\(/ ){
|
elsif ( $line =~ m/\/\// || $line =~ m/\s*typedef / || $line =~ m/\s*struct / || $line =~ m/operator\[\]\(/ ){
|
||||||
|
dbg_info('skipping comment');
|
||||||
$comment = '';
|
$comment = '';
|
||||||
|
$return_type = '';
|
||||||
}
|
}
|
||||||
elsif ( $comment !~ m/^\s*$/ || $return_type ne ''){
|
elsif ( $comment !~ m/^\s*$/ || $return_type ne ''){
|
||||||
if ( $is_override == 1 && $comment =~ m/^\s*$/ ){
|
if ( $is_override == 1 && $comment =~ m/^\s*$/ ){
|
||||||
@ -665,6 +669,7 @@ while ($line_idx < $line_count){
|
|||||||
# parent class Docstring
|
# parent class Docstring
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
dbg_info('writing comment');
|
||||||
push @output, dbg("CM1")."%Docstring\n";
|
push @output, dbg("CM1")."%Docstring\n";
|
||||||
if ( $comment !~ m/^\s*$/ ){
|
if ( $comment !~ m/^\s*$/ ){
|
||||||
push @output, dbg("CM2")."$comment\n";
|
push @output, dbg("CM2")."$comment\n";
|
||||||
|
@ -305,6 +305,11 @@ remove argument
|
|||||||
void position( bool keep, bool keep );
|
void position( bool keep, bool keep );
|
||||||
void position( bool keep );
|
void position( bool keep );
|
||||||
|
|
||||||
|
Whatever &operator[]( int i ) /Factory/;
|
||||||
|
%MethodCode
|
||||||
|
....
|
||||||
|
%End
|
||||||
|
|
||||||
void ZshouldBeShown();
|
void ZshouldBeShown();
|
||||||
|
|
||||||
void methodCodeWithMultiLineDef();
|
void methodCodeWithMultiLineDef();
|
||||||
|
@ -329,6 +329,14 @@ class CORE_EXPORT QgsSipifyHeader : public QtClass<QVariant>, private Ui::QgsBas
|
|||||||
void position( bool keep, bool middle_remove SIP_PYARGREMOVE, bool keep );
|
void position( bool keep, bool middle_remove SIP_PYARGREMOVE, bool keep );
|
||||||
void position( bool keep, bool last_remove SIP_PYARGREMOVE );
|
void position( bool keep, bool last_remove SIP_PYARGREMOVE );
|
||||||
|
|
||||||
|
//! Some comment
|
||||||
|
Whatever &operator[]( int i ) SIP_FACTORY;
|
||||||
|
#ifdef SIP_RUN
|
||||||
|
%MethodCode
|
||||||
|
....
|
||||||
|
%End
|
||||||
|
#endif
|
||||||
|
|
||||||
#if 0
|
#if 0
|
||||||
#if Whatever
|
#if Whatever
|
||||||
void X();
|
void X();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user