develooper Front page | perl.perl5.porters | Postings from November 2013

T_BOOL_2 (Re: [perl.git] branch blead, updated.v5.19.5-363-ge5411d1)

Thread Previous
From:
Tony Cook
Date:
November 18, 2013 22:44
Subject:
T_BOOL_2 (Re: [perl.git] branch blead, updated.v5.19.5-363-ge5411d1)
Message ID:
20131118224425.GD5486@mars.tony.develop-help.com
On Mon, Nov 18, 2013 at 06:18:42PM +0100, Dave Mitchell wrote:
> In perl.git, the branch blead has been updated
> 
> <http://perl5.git.perl.org/perl.git/commitdiff/e5411d1e697dbd2a9c54734aac44ac6189b517e0?hp=9b22382ab51fc1098804b02fdc95ddb5020e0915>
> 
> - Log -----------------------------------------------------------------
> commit e5411d1e697dbd2a9c54734aac44ac6189b517e0
> Author: David Mitchell <davem@iabyn.com>
> Date:   Mon Nov 18 16:48:48 2013 +0000
> 
>     XS::Typemap: silence compiler warning.
>     
>     xsubpp will give us a RETVAL var whether we use it not.
> 
> M	ext/XS-Typemap/Typemap.pm
> M	ext/XS-Typemap/Typemap.xs
> diff --git a/ext/XS-Typemap/Typemap.xs b/ext/XS-Typemap/Typemap.xs
> index a43c843..0eb68e5 100644
> --- a/ext/XS-Typemap/Typemap.xs
> +++ b/ext/XS-Typemap/Typemap.xs
> @@ -440,6 +440,7 @@ bool
>  T_BOOL_2( in )
>    bool in
>   CODE:
> +    PERL_UNUSED_VAR(RETVAL);
>   OUTPUT:
>     in

Making the return value void will suppress RETVAL and the return value
isn't necessary for what this function tests.  Whatever that is.

T_BOOL_2 was added when we were discussing [perl #115796] but didn't
really demonstrate the problem, which T_BOOL_OUT did.

So maybe T_BOOL_2 can just be removed.

Tony

Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About