I'm playing with a sub routine to parse a script and gather a list of variables, but there's one I can't seem to get a handle on. # $q, is the string, in this case... # # "#$hashref->{'hjkjg'} = "isahashreftoo";3sdfgdkjldskjd sdjkdfsklj" while ($q =~ /.*?\$(\w+)-.*?/) { $xref = $1; $q =~ s/\$$xref//; if ((!(defined($hashes{$xref}))) && ($xref !~ /arrays|hashes|scalars/)) { $hashes{$xref} = 1; } } I just want to match '$hashref-' or '$hashref->'. I'm pretty sure that the problem is the '-'. Any ideas? Thanks, Scott ===== Want to unsubscribe from this list? ===== Send mail with body "unsubscribe" to macperl-request@macperl.org