[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-NG] [PATCH 14/15] [ng] cosmetics: avoid redundant use of '&' i
From: |
Stefano Lattarini |
Subject: |
[Automake-NG] [PATCH 14/15] [ng] cosmetics: avoid redundant use of '&' in subroutine calls |
Date: |
Fri, 25 May 2012 13:38:36 +0200 |
* automake.in: Avoid redundant '&' in calls to the subroutines
'push_dist_common', 'define_variable' and 'define_verbose_tagvar'.
Signed-off-by: Stefano Lattarini <address@hidden>
---
automake.in | 50 +++++++++++++++++++++++++-------------------------
1 file changed, 25 insertions(+), 25 deletions(-)
diff --git a/automake.in b/automake.in
index 6e36348..d502506 100644
--- a/automake.in
+++ b/automake.in
@@ -1310,8 +1310,8 @@ sub handle_languages
if (&saw_sources_p (0) && keys %dep_files)
{
# Set location of depcomp.
- &define_variable ('depcomp', INTERNAL,
- '$(SHELL) $(am__config_aux_dir)/depcomp');
+ define_variable ('depcomp', INTERNAL,
+ '$(SHELL) $(am__config_aux_dir)/depcomp');
require_conf_file ("$am_file.am", FOREIGN, 'depcomp');
@@ -1335,7 +1335,7 @@ sub handle_languages
}
else
{
- &define_variable ('depcomp', INTERNAL, '');
+ define_variable ('depcomp', INTERNAL, '');
}
my %done;
@@ -1868,7 +1868,7 @@ sub handle_single_transform ($$$$$%)
unshift (@files, $object);
# Distribute derived sources unless the source they are
# derived from is not.
- &push_dist_common ($object)
+ push_dist_common ($object)
unless ($topparent =~ /^(?:nobase_)?nodist_/);
next;
}
@@ -2037,7 +2037,7 @@ sub handle_source_transform ($$$$%)
msg_var ('unsupported', $ext_var, $ext_var->name . " can assume at most
one value")
if $default_source_ext =~ /[\t ]/;
(my $default_source = $unxformed) =~
s,(\.[^./\\]*)?$,$default_source_ext,;
- &define_variable ($one_file . "_SOURCES", $where, $default_source);
+ define_variable ($one_file . "_SOURCES", $where, $default_source);
push (@sources, $default_source);
push (@dist_sources, $default_source);
@@ -2395,7 +2395,7 @@ sub handle_programs
else
{
# User didn't define prog_LDADD override. So do it.
- &define_variable ($xname . '_LDADD', $where, '$(LDADD)');
+ define_variable ($xname . '_LDADD', $where, '$(LDADD)');
# This does a bit too much work. But we need it to
# generate _DEPENDENCIES when appropriate.
@@ -2458,9 +2458,9 @@ sub handle_libraries
$var->requires_variables ('library used', 'RANLIB');
}
- &define_variable ('AR', INTERNAL, 'ar');
- &define_variable ('ARFLAGS', INTERNAL, 'cru');
- &define_verbose_tagvar ('AR');
+ define_variable ('AR', INTERNAL, 'ar');
+ define_variable ('ARFLAGS', INTERNAL, 'cru');
+ define_verbose_tagvar ('AR');
foreach my $pair (@liblist)
{
@@ -2493,7 +2493,7 @@ sub handle_libraries
if (! var ($xlib . '_AR'))
{
- &define_variable ($xlib . '_AR', $where, '$(AR) $(ARFLAGS)');
+ define_variable ($xlib . '_AR', $where, '$(AR) $(ARFLAGS)');
}
# Generate support for conditional object inclusion in
@@ -2507,7 +2507,7 @@ sub handle_libraries
}
else
{
- &define_variable ($xlib . "_LIBADD", $where, '');
+ define_variable ($xlib . "_LIBADD", $where, '');
}
reject_var ($xlib . '_LDADD',
@@ -2704,7 +2704,7 @@ sub handle_ltlibraries
}
else
{
- &define_variable ($xlib . "_LIBADD", $where, '');
+ define_variable ($xlib . "_LIBADD", $where, '');
}
reject_var ("${xlib}_LDADD",
@@ -3355,7 +3355,7 @@ sub handle_man_pages
$trans_sect_vars{$varname} = 1;
}
- &push_dist_common ($varname)
+ push_dist_common ($varname)
if $pfx eq 'dist_';
}
}
@@ -3390,7 +3390,7 @@ sub handle_man_pages
{
$trans_vars{$varname} = 1;
}
- &push_dist_common ($varname)
+ push_dist_common ($varname)
if $pfx eq 'dist_';
}
}
@@ -3646,14 +3646,14 @@ sub handle_dist ()
# The file might be absent, but if it can be built it's ok.
|| rule $cfile)
{
- &push_dist_common ($cfile);
+ push_dist_common ($cfile);
}
# Don't use 'elsif' here because a file might meaningfully
# appear in both directories.
if ($check_aux && dir_has_case_matching_file ($config_aux_dir, $cfile))
{
- &push_dist_common ("$config_aux_dir/$cfile")
+ push_dist_common ("$config_aux_dir/$cfile")
}
}
@@ -3776,7 +3776,7 @@ sub scan_aclocal_m4 ()
if (-f 'aclocal.m4')
{
- &define_variable ("ACLOCAL_M4", INTERNAL, '$(top_srcdir)/aclocal.m4');
+ define_variable ("ACLOCAL_M4", INTERNAL, '$(top_srcdir)/aclocal.m4');
my $aclocal = new Automake::XFile "< aclocal.m4";
my $line = $aclocal->getline;
@@ -4563,7 +4563,7 @@ sub handle_emacs_lisp
require_variables ($elfiles[0][0], "Emacs Lisp sources seen", TRUE,
'EMACS', 'lispdir');
require_conf_file ($elfiles[0][0], FOREIGN, 'elisp-comp');
- &define_variable ('elisp_comp', INTERNAL,
'$(am__config_aux_dir)/elisp-comp');
+ define_variable ('elisp_comp', INTERNAL, '$(am__config_aux_dir)/elisp-comp');
}
# Handle Python
@@ -4575,7 +4575,7 @@ sub handle_python
require_variables ($pyfiles[0][0], "Python sources seen", TRUE, 'PYTHON');
require_conf_file ($pyfiles[0][0], FOREIGN, 'py-compile');
- &define_variable ('py_compile', INTERNAL,
'$(am__config_aux_dir)/py-compile');
+ define_variable ('py_compile', INTERNAL, '$(am__config_aux_dir)/py-compile');
}
# Handle Java.
@@ -5529,7 +5529,7 @@ sub lang_yacc_target_hook
# Distribute the generated file, unless its .y source was
# listed in a nodist_ variable. (&handle_source_transform
# will set DIST_SOURCE.)
- &push_dist_common ($header)
+ push_dist_common ($header)
if $transform{'DIST_SOURCE'};
# The GNU rules say that yacc/lex output files should be removed
@@ -5562,7 +5562,7 @@ sub yacc_lex_finish_helper
# FIXME: for now, no line number.
require_conf_file ($configure_ac, FOREIGN, 'ylwrap');
- &define_variable ('YLWRAP', INTERNAL, '$(am__config_aux_dir)/ylwrap');
+ define_variable ('YLWRAP', INTERNAL, '$(am__config_aux_dir)/ylwrap');
}
sub lang_yacc_finish
@@ -5991,9 +5991,9 @@ sub define_linker_variable ($)
$link = "\$(LIBTOOL) $verbose $libtool_tag\$(AM_LIBTOOLFLAGS) "
. "\$(LIBTOOLFLAGS) --mode=link ";
}
- &define_variable ($lang->linker, INTERNAL, $link . $lang->link);
- &define_variable ($lang->compiler, INTERNAL, $lang);
- &define_verbose_tagvar ($lang->lder || 'GEN');
+ define_variable ($lang->linker, INTERNAL, $link . $lang->link);
+ define_variable ($lang->compiler, INTERNAL, $lang);
+ define_verbose_tagvar ($lang->lder || 'GEN');
}
sub define_per_target_linker_variable ($$)
@@ -6040,7 +6040,7 @@ sub define_per_target_linker_variable ($$)
return ($lang->linker, $lang->lder)
if $link_command eq $orig_command;
- &define_variable ("${target}_LINK", INTERNAL, $link_command);
+ define_variable ("${target}_LINK", INTERNAL, $link_command);
return ("${target}_LINK", $lang->lder);
}
--
1.7.9.5
- [Automake-NG] [PATCH 07/15] [ng] VarDef: store comments and values as a perl array, (continued)
- [Automake-NG] [PATCH 07/15] [ng] VarDef: store comments and values as a perl array, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 03/15] [ng] vars: get rid of VAR_SILENT type, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 08/15] [ng] vars: simplify logic for appending conditionally, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 06/15] [ng] refactor: support comments only for VarDef, not for ItemDef too, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 09/15] [ng] vars: keep track of conditionals in appended values and comments, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 11/15] [ng] refactor: change signature of 'define_variable()', Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 13/15] [ng] rename: define_pretty_variable -> define_cond_variable(), Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 10/15] [ng] vars: get rid of VAR_ASIS / VAR_PRETTY distinction, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 15/15] [ng] vars: remove some safety checks in Automake::Variable::define, Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 12/15] [ng] cleanup: prefer 'define_variable' over 'define_pretty_variable', Stefano Lattarini, 2012/05/25
- [Automake-NG] [PATCH 14/15] [ng] cosmetics: avoid redundant use of '&' in subroutine calls,
Stefano Lattarini <=