Skip to content

Commit 169c609

Browse files
committedApr 3, 2017
[sipify] fix override removal
1 parent cca83b7 commit 169c609

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed
 

‎scripts/sipify.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ sub processDoxygenLine
287287

288288
do {no warnings 'uninitialized';
289289
# remove keywords
290-
$line =~ s/\s*override( SIP_\w+(\(.+\))?)?;/$1;/;
290+
$line =~ s/\s*\boverride\b//;
291291
$line =~ s/^(\s*)?(const )?(virtual |static )?inline /$1$2$3/;
292292
$line =~ s/\bnullptr\b/0/g;
293293
$line =~ s/\s*=\s*default\b//g;
@@ -321,7 +321,7 @@ sub processDoxygenLine
321321
}
322322

323323
# remove function bodies
324-
if ( $line =~ m/^(\s*)?(const )?(virtual |static )?((\w+(<.*?>)?\s+(\*|&)?)?(\w+|operator.)\(.*?(\(.*\))*.*\)( (?:const|SIP_[A-Z_]*?))*)\s*(override)?\s*(\{.*\})?(?!;)(\s*\/\/.*)?$/ ){
324+
if ( $line =~ m/^(\s*)?(const )?(virtual |static )?((\w+(<.*?>)?\s+(\*|&)?)?(\w+|operator.)\(.*?(\(.*\))*.*\)( (?:const|SIP_[A-Z_]*?))*)\s*(\{.*\})?(?!;)(\s*\/\/.*)?$/ ){
325325
my $newline = "$1$2$3$4;\n";
326326
if ($line !~ m/\{.*?\}$/){
327327
$line = readline $header;

0 commit comments

Comments
 (0)
Please sign in to comment.