Suppress empty #ifdef blocks in embed.pl
Hugo van der Sanden [Mon, 17 Feb 2003 09:06:44 +0000 (09:06 +0000)]
p4raw-id: //depot/perl@18734

embed.h
embed.pl

diff --git a/embed.h b/embed.h
index 813512a..a5bb315 100644 (file)
--- a/embed.h
+++ b/embed.h
 #ifdef PERL_CORE
 #define peep                   Perl_peep
 #endif
-#ifdef PERL_CORE
-#endif
 #if defined(USE_REENTRANT_API)
 #define reentrant_size         Perl_reentrant_size
 #define reentrant_init         Perl_reentrant_init
 #define sv_eq                  Perl_sv_eq
 #define sv_free                        Perl_sv_free
 #ifdef PERL_CORE
-#endif
-#ifdef PERL_CORE
 #define sv_free_arenas         Perl_sv_free_arenas
 #endif
 #define sv_gets                        Perl_sv_gets
index 9e5c62b..598ebcc 100755 (executable)
--- a/embed.pl
+++ b/embed.pl
@@ -344,7 +344,7 @@ walk_table {
                $ret .= hide($func,"Perl_$func");
            }
        }
-         unless ($flags =~ /A/) {
+       if ($ret ne '' && $flags !~ /A/) {
            if ($flags =~ /E/) {
                $ret = "#if defined(PERL_CORE) || defined(PERL_EXT)\n$ret#endif\n";
            } else {