]> git.ipfire.org Git - thirdparty/automake.git/commitdiff
cleanup: remove unused '&count_files_for_language' subroutine
authorStefano Lattarini <stefano.lattarini@gmail.com>
Thu, 7 Jun 2012 17:13:39 +0000 (19:13 +0200)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Fri, 8 Jun 2012 20:01:53 +0000 (22:01 +0200)
* automake.in (count_files_for_language): Remove.  Its only remaining
caller (saw_sources_p) has stopped calling it in the previous commit.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
automake.in

index af9fb5b096db9d00098730e6d54fe183fa9d650f..8c02016d736d897fd234fd8bc5b1dca0d97378f1 100644 (file)
@@ -6038,44 +6038,6 @@ sub saw_extension
     }
 }
 
-# Return the number of files seen for a given language.  Knows about
-# special cases we care about.  FIXME: this is hideous.  We need
-# something that involves real language objects.  For instance yacc
-# and yaccxx could both derive from a common yacc class which would
-# know about the strange ylwrap requirement.  (Or better yet we could
-# just not support legacy yacc!)
-sub count_files_for_language
-{
-    my ($name) = @_;
-
-    my @names;
-    if ($name eq 'yacc' || $name eq 'yaccxx')
-    {
-       @names = ('yacc', 'yaccxx');
-    }
-    elsif ($name eq 'lex' || $name eq 'lexxx')
-    {
-       @names = ('lex', 'lexxx');
-    }
-    else
-    {
-       @names = ($name);
-    }
-
-    my $r = 0;
-    foreach $name (@names)
-    {
-       my $lang = $languages{$name};
-       foreach my $ext (@{$lang->extensions})
-       {
-           $r += $extension_seen{$ext}
-               if defined $extension_seen{$ext};
-       }
-    }
-
-    return $r
-}
-
 # Called to ask whether source files (not headers) have been seen.
 sub saw_sources_p
 {