my @local_vars; $#local_vars=5; #(don't like the literal 5, but haven't gotten so far as to worry about that yet) push @{$this}->{local_vars}}, \@local_vars; #create space for this tag's vars assign_names(qw (open_tag, tagprint, cur_class, cur_id, defines_class, defines_id), \@local_vars); ## this is the questionable 'magic' part... # now...can use names as one would use local vars.... if ($open_tag eq 'div' and $cur_class eq 'pager') {...