Patch #1454481: Make thread stack size runtime tunable.

Heavily revised, comprising revisions:
46640 - original trunk revision (backed out in r46655)
46647 - markup fix (backed out in r46655)
46692:46918 merged from branch aimacintyre-sf1454481

branch tested on buildbots (Windows buildbots had problems
not related to these changes).
This commit is contained in:
Andrew MacIntyre 2006-06-13 15:04:24 +00:00
parent c6f5b3ad6c
commit 9291332de1
14 changed files with 349 additions and 6 deletions

View file

@ -20,6 +20,7 @@ __all__ = ['error', 'start_new_thread', 'exit', 'get_ident', 'allocate_lock',
'interrupt_main', 'LockType']
import traceback as _traceback
import warnings
class error(Exception):
"""Dummy implementation of thread.error."""
@ -75,6 +76,13 @@ def allocate_lock():
"""Dummy implementation of thread.allocate_lock()."""
return LockType()
def stack_size(size=None):
"""Dummy implementation of thread.stack_size()."""
if size is not None:
msg = "setting thread stack size not supported on this platform"
warnings.warn(msg, RuntimeWarning)
return 0
class LockType(object):
"""Class implementing dummy implementation of thread.LockType.