Subject: Developers of Sympa
List archive
- From: David Verdin <address@concealed>
- To: address@concealed
- Subject: Re: [sympa-developpers] Working on repository
- Date: Tue, 25 Feb 2014 11:48:01 +0100
Dear all, Sorry for delayed answer. I had a lot of operational stuff to do recently. Le 24/02/14 14:29, Guillaume Rousse a
écrit :
address@concealed">Le 18/02/2014 04:33, IKEDA Soji a écrit :Definitely! I'm in favour of B for clarity AND for not having to wonder the parameters order when calling a sub. However, I think it is important to test the presence / absence of expected parameters just after the "my (%params) = @_;" and translate them into local variables. We could even undef the %params hash just after converting its values to local variables. That way, if we had a new key/value to the params hash and try to use it directly in the code a $hash{$key}, we woul find the b_ug at compile time. So that could turn to: B) named parameters sub foo { my (%params) = @_; my $email = $params{'email'}; my $action = "$params{'action'}; undef %params; ... do_something($email); # Would work do_something($params{'option'}); # Would issue in strict mode '%params needs to be defined...' } foo(email => $a, action =">" $b, option => $c); address@concealed"> before it turns out into yet another ping-pong discussion between Soji and myself ? address@concealed">Same here. --
A bug in Sympa? Quick! To the bug tracker!
|
Attachment:
smime.p7s
Description: Signature cryptographique S/MIME
-
Re: [sympa-developpers] Working on repository,
David Verdin, 02/05/2014
- Re: [sympa-developpers] Working on repository, Marc Chantreux, 02/05/2014
-
Re: [sympa-developpers] Working on repository,
IKEDA Soji, 02/05/2014
-
Re: [sympa-developpers] Working on repository,
David Verdin, 02/05/2014
-
Re: [sympa-developpers] Working on repository,
IKEDA Soji, 02/06/2014
-
Re: [sympa-developpers] Working on repository,
Guillaume Rousse, 02/10/2014
-
Re: [sympa-developpers] Working on repository,
IKEDA Soji, 02/11/2014
-
Re: [sympa-developpers] Working on repository,
Guillaume Rousse, 02/17/2014
- Re: [sympa-developpers] Working on repository, IKEDA Soji, 02/18/2014
- Re: [sympa-developpers] Working on repository, Guillaume Rousse, 02/24/2014
- Re: [sympa-developpers] Working on repository, David Verdin, 02/25/2014
- Re: [sympa-developpers] Working on repository, IKEDA Soji, 02/25/2014
- Re: [sympa-developpers] Working on repository, Guillaume Rousse, 02/26/2014
- Re: [sympa-developpers] Working on repository, Guillaume Rousse, 02/26/2014
- Re: [sympa-developpers] Working on repository, David Verdin, 02/26/2014
- [sympa-developpers] subroutine template was Re: Working on repository, IKEDA Soji, 02/27/2014
-
Re: [sympa-developpers] Working on repository,
Guillaume Rousse, 02/17/2014
-
Re: [sympa-developpers] Working on repository,
IKEDA Soji, 02/11/2014
-
Re: [sympa-developpers] Working on repository,
Guillaume Rousse, 02/10/2014
-
Re: [sympa-developpers] Working on repository,
IKEDA Soji, 02/06/2014
-
Re: [sympa-developpers] Working on repository,
David Verdin, 02/05/2014
Archive powered by MHonArc 2.6.19+.