I use the feature of passing an explicit dictionary for the following
reason. I have a database with named entries on which I wish to perform
calculations. To evaluate an expression of the variables names, I create
an object with features named as the database entries are (by taking an
empty class and adding the features to it), then pass the objects
dictionary as the local namespace to the exec() call. That way I don't
have to parse the expression or clutter the local name space with
variables of the same name as the db entries. How could I accomplish the
same after your proposed changes?
--Jon
-- Jon Eisenberg High Energy Physics Lab e-mail: jke@u.washington.edu Physics Dept., FM-15 (or jke@uwaphast.bitnet) Univ. of Washington phone: 206-543-6886 office Seattle, WA 98195 fax: 206-685-0635