Skip to content
Permalink
Browse files

Fix abstract MOCed class generation

  • Loading branch information
m-kuhn committed Nov 1, 2017
1 parent c3e2adc commit e0c1f0b050e4e5e1b6d63bb945afdd1011b5c26f
Showing with 2 additions and 2 deletions.
  1. +2 −2 scripts/sipify.pl
@@ -210,7 +210,7 @@ sub remove_following_body_or_initializerlist {
sub fix_annotations {
my $line = $_[0];
# printed annotations
$line =~ s/\b\/\/\s*SIP_ABSTRACT\b/\/Abstract\//;
$line =~ s/\/\/\s*SIP_ABSTRACT\b/\/Abstract\//;
$line =~ s/\bSIP_ABSTRACT\b/\/Abstract\//;
$line =~ s/\bSIP_ALLOWNONE\b/\/AllowNone\//;
$line =~ s/\bSIP_ARRAY\b/\/Array\//g;
@@ -513,7 +513,7 @@ sub detect_comment_block{

# class declaration started
# https://regex101.com/r/6FWntP/10
if ( $LINE =~ m/^(\s*class)\s+([A-Z]+_EXPORT\s+)?(\w+)(\s*\:\s*(public|protected|private)\s+\w+(< *(\w|::)+ *>)?(::\w+(<\w+>)?)*(,\s*(public|protected|private)\s+\w+(< *(\w|::)+ *>)?(::\w+(<\w+>)?)*)*)?(?<annot>\s*SIP_\w+)?\s*?(\/\/.*|(?!;))$/ ){
if ( $LINE =~ m/^(\s*class)\s+([A-Z]+_EXPORT\s+)?(\w+)(\s*\:\s*(public|protected|private)\s+\w+(< *(\w|::)+ *>)?(::\w+(<\w+>)?)*(,\s*(public|protected|private)\s+\w+(< *(\w|::)+ *>)?(::\w+(<\w+>)?)*)*)?(?<annot>\s*\/?\/?\s*SIP_\w+)?\s*?(\/\/.*|(?!;))$/ ){
dbg_info("class definition started");
push @ACCESS, PUBLIC;
push @EXPORTED, 0;

0 comments on commit e0c1f0b

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