summaryrefslogtreecommitdiff
path: root/lib/ExtUtils
diff options
context:
space:
mode:
authorTim Bunce <Tim.Bunce@ig.co.uk>1997-01-27 16:59:06 +0000
committerChip Salzenberg <chip@atlantic.net>1997-01-29 18:11:00 +1200
commit6c5fb52b645bfa15a7252f6d5be4457f847709b7 (patch)
tree50e71e59f7e73decc332762cf8cee0f5f3a2aa30 /lib/ExtUtils
parent6d5cdeed8354ee0a0c6ca8a52abf57d6b5a67b41 (diff)
downloadperl-6c5fb52b645bfa15a7252f6d5be4457f847709b7.tar.gz
xsubpp handing of void funcs breaks extensions using XST_m*()
private-msgid: <9701271659.AA15137@toad.ig.co.uk>
Diffstat (limited to 'lib/ExtUtils')
-rwxr-xr-xlib/ExtUtils/xsubpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/ExtUtils/xsubpp b/lib/ExtUtils/xsubpp
index 74e325013c..d655a26ba6 100755
--- a/lib/ExtUtils/xsubpp
+++ b/lib/ExtUtils/xsubpp
@@ -842,7 +842,10 @@ while (fetch_para()) {
$PPCODE = grep(/^\s*PPCODE\s*:/, @line);
$CODE = grep(/^\s*CODE\s*:/, @line);
- $EXPLICIT_RETURN = $CODE && ("@line" =~ /\bST\s*\([^;]*=/ );
+ # Detect CODE: blocks which use ST(n)= or XST_m*(n,v)
+ # to set explicit return values.
+ $EXPLICIT_RETURN = ($CODE &&
+ ("@line" =~ /(\bST\s*\([^;]*=) | (\bXST_m\w+\s*\()/x ));
$ALIAS = grep(/^\s*ALIAS\s*:/, @line);
# print function header