Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2013-08-27
11:08 • Closed ticket [526299ffff]: New Tcl_IsThreaded C-API call plus 9 other chang... artifact: 5edf1de489 user: jan.nijtmans
2002-03-06
09:01 • New ticket [526299ffff]. artifact: 5927593787 user: vasiljevic

New Tcl_IsThreaded C-API call

Closed / Wont Fix526299ffffffffffffffffffffffffffffffffffCreated 25 years agoUpdated 13 years ago
Descriptionplain2002-03-06 09:01:12
Tcl extension and/or C-level code should be able to dynamically find-out whether running under Tcl core 
compiled for threads or not. 
This can be achieved in a simple matter as with 
Tcl_IsSafe() and friends.
jan.nijtmanswiki2013-08-27 11:08:37

A very easy solution can be found here: http://core.tcl.tk/thread/artifact/317ee615b2?ln=447-454. If Tcl is not compiled with thread support, the call Tcl_MutexLock(&threadMutex) will be a dummy call, so threadMutex will be NULL afterwards. As Tcl 8.6 is compiled with Threads by default, this is no longer a real issue.

Log in (anonymous is fine) to add a comment.