X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=embed.pl;h=2e473b60651392e4f32ef0348b68e96197114cc1;hb=9df548ee6c72d2540cc8aac7e738eff1202a7278;hp=67e142a723f2e25f3a6548a2db393bdc65baad53;hpb=5ca37ce9a896d8d8db4aa0d3ecf10ef4edb561a0;p=p5sagit%2Fp5-mst-13.2.git diff --git a/embed.pl b/embed.pl index 67e142a..2e473b6 100755 --- a/embed.pl +++ b/embed.pl @@ -49,7 +49,8 @@ sub walk_table (&@) { else { @args = split /\s*\|\s*/, $_; } - print $F $function->(@args); + my @outs = &{$function}(@args); + print $F @outs; # $function->(@args) is not 5.003 } print $F $trailer if $trailer; close $F unless ref $filename; @@ -251,7 +252,8 @@ readvars %intrp, 'intrpvar.h','I'; readvars %thread, 'thrdvar.h','T'; readvars %globvar, 'perlvars.h','G'; -foreach my $sym (sort keys %thread) { +my $sym; +foreach $sym (sort keys %thread) { warn "$sym in intrpvar.h as well as thrdvar.h\n" if exists $intrp{$sym}; } @@ -856,15 +858,15 @@ START_EXTERN_C EOT -foreach my $sym (sort keys %intrp) { +foreach $sym (sort keys %intrp) { print CAPIH bincompat_var('I',$sym); } -foreach my $sym (sort keys %thread) { +foreach $sym (sort keys %thread) { print CAPIH bincompat_var('T',$sym); } -foreach my $sym (sort keys %globvar) { +foreach $sym (sort keys %globvar) { print CAPIH bincompat_var('G',$sym); } @@ -985,7 +987,7 @@ sub emit_func { if (length $return) { $decl .= " $rettype retval;\n"; $retarg .= "retval = "; - $return = "\n ${return}retval;\n"; + $return = "\n " . $return . "retval;\n"; } $emitval .= <