Find all variables used.

Hi, Is there a way (apart from grepping) to list out all the variables (viz., scalars/array/hashes/code/etc. ) that have been declared &/or used in a perl program? The variables are of the package/lexical/local/global variety. Thanks, Rakesh