[Python-Dev] Changing the Division Operator -- PEP 238, rev 1.12

Michael Hudson mwh@python.net
10 Aug 2001 04:17:13 -0400


"Tim Peters" <tim.one@home.com> writes:

> [Michael Hudson]
> > Hmm.  While I agree that 'or'ing is the best thing to do by default,
> > it would be nice if there was some way of requesting a blank starting
> > point (this is the other unresolved issue in PEP 236, after all).
> > Maybe it's not worth it.
> 
> Well, there's no reason at all to believe that whatever future statements
> IDLE and doctest (for examples) happen to use in their own implementations
> are also appropriate for the user-code they're simulating.  So the problem
> isn't solved in full unless that connection can be broken (is that hard?
> offhand it *sounds* like it just needs another yes/no argument).

It's a matter of interface, really.  It's certainly not at all
technically hard.  Maybe:

   compile(text, filename, symbol[, flags[, dont_inherit]])

I worry that saying "you don't inherit behaviour from surrounding code
as soon as you pass a flag" might get really, really confusing at
times.

> OTOH, IDLE and doctest (for examples) can easily enough be written
> to use no future-stmts at all of their own, so that code compiled
> from them gets a blank starting point.  Whether that remains easy
> down the road depends on how silly we get in introducing stupid
> future stmts <0.9 wink>.

This is indeed the issue.

we-need-a-tritfield-ly y'rs
M.

-- 
  Important data should not be entrusted to Pinstripe, as it may
  eat it and make loud belching noises.
   -- from the announcement of the beta of "Pinstripe" aka. Redhat 7.0