Skip to content
Tcl Source Code Artifact [f90be68758]
Login

Artifact [f90be68758]

Artifact f90be68758b7b95dc952a13862681e03d3f8e040:

Wiki page [Timer Events] by dgp on 2014-09-14 20:42:02.
D 2014-09-14T20:42:02.567
L Timer\sEvents
P 8005ecccfc7077f720a9b2b057d018fd579c9d4f
U dgp
W 1259
<h1>Source Files</h1>
  *  portions of [/finfo?name=generic/tclTimer.c|tclTimer.c]

<h1>Public Interface</h1>
  *  Tcl_CreateTimerHandler
  *  Tcl_DeleteTimerHandler
  *  Tcl_DoWhenIdle
  *  Tcl_CancelIdleCall

<h1>Private Interface</h1>
  *  TclCreateAbsoluteTimerHandler
  *  TclServiceIdle

<h1>Directly Depends On Public Interface</h1>
  *  [Threads]
  *  [Allocation]
  *  [Event Loops]
  *  [Time Measurement]
  *  [Notifier]

<h1>Directly Depends On Private Interface of</h1>
  *  [Threads]
 
<h1>Discussion</h1>

The private dependency is on <b>TclThreadDataKeyGet</b> which appears easily
convertible to <b>Tcl_GetThreadData</b>.

The private routine <b>TclCreateAbsoluteTimerHandler</b> appears to exist
just so that <b>Tcl_LimitSetTime</b> doesnt have to pass through milliseconds
(and the loss of precision implicit in that conversion).  Since <b>Tcl_Time</b> values
are already in the public Tcl interface, this would be a good routine to make public,
though perhaps with a name change.

Unless something is using it from the private stubs table, the only callers of
<b>TclServiceIdle</b> are <b>Tcl_DoOneEvent</b> and <b>Tcl_ServiceAll</b>,
so that connection might be resolved by redrawing module boundaries.
Z 3accfb830822d91cd2e777647157e7d4