Something simple like this could be a start (with filenames given on the command line):
use strict; use warnings; my %identifiers; undef $/; undef @identifiers{ /((?:sub\s+|[\$@%])[a-zA-Z_][a-zA-Z_0-9]*)/g } whi +le <>; print join "\n", keys %identifiers;
but there are more things to find, like module names etc.
In reply to Re: Code Reviews -- List Identifiers
by hdb
in thread Code Reviews -- List Identifiers
by QM
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |