Armin Rigo wrote:
Hi Mark,

On Sun, Mar 4, 2012 at 18:34, Mark Shannon <m...@hotpy.org> wrote:
You can't solve the too much time, without solving the halting problem,

Not sure what you mean by that.  It seems to me that it's particularly
easy to do in a roughly portable way, with alarm() for example on all
UNIXes.

What time should you set the alarm for? How much time is enough before you decide that a piece of code is taking too long?

The halting problem is not that you can't breaking out of an infinite loop, but that you can't *in general* decide when you are in an infinite loop.

I think that Mark's point is that you can't, in general, tell when you are in a "too much time" attack (or bug) that needs to be broken out of rather than just a legitimately long calculation which will terminate if you wait just a little longer.


--
Steven

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to