[Tutor] How can I make Python Shell see new version of function subroutine?
Kermit Rose
kermit at polaris.net
Sun Feb 19 23:03:23 CET 2006
From: John Fouhy
Date: 02/19/06 16:33:18
To: Python Tutor
Subject: [Tutor] Bug in python
See: http://docs.python.org/ref/summary.html
*, / and % all have the same precedence. I guess the reasoning is
that / is (approximately) the inverse of * and % is "remainder after
/".
Hello John.
Ok. I got steamed too quickly.
**********
> Also, why am I getting a syntax error in the following?
When you're using the interactive interpreter, you need to end a
function definition with an extra carriage return.
(at least, that's the way it works in the console version)
******************************
I believe you. However, when I added extra carriage returns to the script
file
between the function subroutines, it made no difference.
Why? Is it because the windows copy and paste throws away the extra
carriage returns?
I pasted the function subroutines, one at a time, into the shell, and
entered the carriage return
directly into the shell between copies, and it worked.
However, I have a debugging dilemma.
I made changes to one of the function subroutines, and recopied that
function to the shell
and I put print statements in the new version of the function subroutine.
None of the new print statements are printing.
It's as if the old version is still runing.
Is there anything short of closing the shell and re-opening it that I can do to fix this?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/tutor/attachments/20060219/4b7c93a2/attachment.html
More information about the Tutor
mailing list