]> git.imager.perl.org - imager.git/commitdiff
gcov the derived .c file as well as the .xs or .im file
authorTony Cook <tony@develop-help.com>
Fri, 24 May 2013 13:12:49 +0000 (23:12 +1000)
committerTony Cook <tony@develop-help.com>
Fri, 24 May 2013 13:12:49 +0000 (23:12 +1000)
imcover.perl

index 6a05efb42daf474a429d3c45440d33a3c7370415..5c75c4386345493365479d365111013d50d09eb4 100644 (file)
@@ -52,6 +52,14 @@ for my $filename (keys %$mani) {
   else {
     push @{$paths{''}}, $filename;
   }
+  if ($filename =~ s/\.(xs|im)$/.c/) {
+    if ($filename =~ m!^(\w+)/(\w+\.\w+)$!) {
+      push @{$paths{$1}}, $2;
+    }
+    else {
+      push @{$paths{''}}, $filename;
+    }
+  }
 }
 
 for my $path (keys %paths) {