OK, here is my proposal.

I think clearly the namespace injection thing is very useful in some  
*specific* contexts,
for example, interactive commutative algebra. In many other contexts it  
could suck
because its potentially confusing.  Thus here is my proposal.

(1) The default behavior is exactly as in Python 1.4, i.e., no namespace  
injection
     and one has the R.<x,y,z> = PolynomialRing(QQ,3) constructor.  I'll  
rework the
     preparser to make sure this can be done with violating global  
uniqueness of
     parent structures (i.e., I'll not use assign_names).

(2) There is a mode that users can turn on if they want, which does the  
namespace
     injection.  They type inject_on() to turn it on.  They can put this in  
their
     init.sage startup file.  Doing inject_on replaces certain constructors  
with
     wrappers that do namespace injection.

(3) If R is any structure with generators, R.inject_names(dict) will inject
     the variable names of R into the given dictionary (which, e.g., could  
be globals()).

  -- William

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to