Skip to content
Tcl Source Code View Ticket
Login

View Ticket

tip#609 proposed implementation

Closed / Fixed236d660fd81c28a416dcfdc969f2f28f20fc2ffcCreated 5 years agoUpdated 20 days ago
Descriptionwiki2021-08-11 12:23:36
The attached tip609.diff contains an implementation for tip#609. The diff is against [e55cd6d5bf44bde46c0cbd4b127b29d82edd2d59].
jan.nijtmanswiki2021-08-15 21:57:02

Thanks. My only remark is that instead of 2 new flags `TCL_QUEUE_HEAD_ALERT_IF_EMPTY`/`TCL_QUEUE_TAIL_ALERT_IF_EMPTY` I would prefer a single new flag TCL_QUEUE_ALERT_IF_EMPTY which can be combined with the other flags. See: [c7572c6dc42e6380]. This way we don't need the clumsy `Tcl_QueuePositionEx` any more. Please review my proposed changes!

chwwiki2021-08-16 07:09:26

Thanks for making it into a new branch. The solution with a single TCL_QUEUE_ALERT_IF_EMPTY flag is equivalent but please Jan or Harald change the TIP's text and example accordingly. And I think that an additional preprocessor symbol is still needed in order to be able to allow for conditional compilation for older cores without that feature (future/backward/forward/past compatibility).

jan.nijtmanswiki2021-08-17 16:04:46

TIP is adapted to implementation now. Just one question remains: Is the TCL_QUEUE_ALERT_IF_EMPTY flag supposed to work together with TCL_QUEUE_MARK too? If yes, then the implementation should be adapted to allow that. If no, that should be reflected in the TIP and the documentation. That's my only remaining remark.

Thanks!

chwwiki2021-08-17 16:49:42

Searching for TCL_QUEUE_MARK over the entire AndroWish source tree gives few hits and in Tk only. The usage is not bound to multiple threads. Thus, I believe, it is not necessary to have TCL_QUEUE_ALERT_IF_EMPTY for the queue mark operation.

serhiy.storchakawiki2026-11-13 11:18:44

TIP 609 was merged in [901c88bb0e] with the single TCL_QUEUE_ALERT_IF_EMPTY flag and is in Tcl 9.0.

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

Attachments: