> The output I got was not what I expected. Was this a bug?
Maybe not strictly, but it is a hoot <grin>! The new feature is that '_'
is automatically set to the result of the last auto-printed expression.
So I think what's happening is:
1) vars() returns the namespace N == {'__name__': '__main__'}.
2) The auto-printer '_' hack binds '_' to N before printing, which
changes the namespace to N == {'__name__': '__main__, '_': N}.
3) The attempt to print N == {'__name__': '__main__, '_': N} then falls
into infinite recursion.
At least that matches the symptoms.
speculatingly y'rs - tim
Tim Peters tim@ksr.com
not speaking for Kendall Square Research Corp