What is a type error? [correction]
Darren New
dnew at san.rr.com
Mon Jul 17 16:18:20 EDT 2006
Darren New wrote:
> Now, if the "insert line into inputs" actually unset "line", then yes,
> you're right, Hermes would complain about this.
Oh, I see. You translated from Hermes into Java, and Java doesn't have
the "insert into" statement. Indeed, the line you commented out is
*exactly* what's important for analysis, as it unsets line.
Had it been
insert copy of line into inputs
then you would not have gotten any complaint from Hermes, as it would
not have unset line there.
In this case, it's equivalent to
if (!is_line) line = getString();
if (!is_line) use line for something...
except the second test is at the top of the loop instead of the bottom.
--
Darren New / San Diego, CA, USA (PST)
This octopus isn't tasty. Too many
tentacles, not enough chops.
More information about the Python-list
mailing list