diff options
author | Nicholas Clark <nick@ccl4.org> | 2010-09-30 11:31:40 +0100 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2010-09-30 11:32:17 +0100 |
commit | b2e549c0b5ccc745d727de4e27634e8090b0f719 (patch) | |
tree | df827f68e9973c739c6d35a41bde3b8e1a17330f /embed.pl | |
parent | 2a4d8072390905d051b0d9f7d2098b1c97899cdc (diff) | |
download | perl-b2e549c0b5ccc745d727de4e27634e8090b0f719.tar.gz |
Merge adjacent #ifndef PERL_IMPLICIT_CONTEXT blocks in embed.h
Diffstat (limited to 'embed.pl')
-rwxr-xr-x | embed.pl | 8 |
1 files changed, 8 insertions, 0 deletions
@@ -532,6 +532,14 @@ sub embed_h { # Prune empty #if/#endif pairs. while ($lines =~ s/#\s*if[^\n]+\n#\s*endif\n//) { } + # Merge adjacent blocks. + while ($lines =~ s/(#ifndef PERL_IMPLICIT_CONTEXT +[^\n]+ +)#endif +#ifndef PERL_IMPLICIT_CONTEXT +/$1/) { + } + print $em $lines; print $em "#endif\n" if $guard; } |