Artifacts Associated With Ticket 2412068
Ticket change [52b4504c25] (rid 126362) by venksi on 2008-12-09 16:19:54:
- assignee initialized to: "nobody"
- cmimetype initialized to: "text/plain"
- comment initialized to:
Short example: # Start of a.tcl proc main {} { uplevel #0 { source b.tcl } } coroutine m main # end of a.tcl # start of b.tcl yield # end of b.tcl On Running this as: c:/tcl/8.6a4-2008-12-07/bin/tclsh86.exe a.tcl I get this error: cannot yield: C stack busy while executing "yield" (file "b.tcl" line 1) invoked from within "source b.tcl" ("uplevel" body line 2) invoked from within "uplevel #0 { source b.tcl }" (procedure "main" line 2) invoked from within "main" invoked from within "coroutine m main" (file "a.tcl" line 9) - foundin initialized to: "obsolete: 8.6a4"
- is_private initialized to: "0"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "venksi"
- subsystem initialized to: "None"
- title initialized to: "[source] is not yield-able"
- type initialized to: "Bug"
Ticket change [8ce56d2e8a] (rid 127813) by dkf on 2008-12-09 23:25:45:
- assignee changed to: "msofer"
- priority changed to: "7 High"
- subsystem changed to: "45. Parsing and Eval"
Ticket change [8663d6aee6] (rid 131501) by venksi on 2008-12-12 00:26:04:
- icomment:
As a very temporary workaround (that my work for only me): rename ::source ::old_source proc ::source args { if {[llength $args] > 1} { uplevel 1 [linsert $args 0 ::old_source] } else { set fi [open [lindex $args 0]] set r [read $fi] close $fi uplevel 1 $r } } That takes care of my simple case where the users do not pass flags to source. But the proc must handle it because many tcl libraries do. This allows files which are sourced as just "source <name>" to be able to use yield. - login: "venksi"
- mimetype: "text/plain"
- username: "venksi"
- icomment:
Ticket change [09430c6fad] (rid 89691) by dkf on 2009-01-05 16:50:49:
- icomment:
Turned out to be simpler than I expected, but I'm not sure that the TIP#280 dictionary generated by [info frame 0] at the top-level in a sourced file is quite correct in all cases (sourcing from ::unknown seems different in some circumstances). If anyone has problems, they can submit a bug report...
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [01502ed9f8] (rid 119460) by dkf on 2009-01-05 16:50:50:
- assignee changed to: "dkf"
- closedate changed to: "2009-01-05T09:50:50"
- closer changed to: "dkf"
- resolution changed to: "Fixed"
- status changed to: "Closed"
Ticket change [f5505e0a49] (rid 130083) by dkf on 2009-01-05 19:28:22:
- icomment:
I was mistaken, and the TIP#280 hairball has claimed me for sure. :-( (Why there are so many subtle differences between different Eval-like APIs, I just do not know...)
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [5c5a1fe668] (rid 115285) by dkf on 2009-01-05 19:28:23:
- status changed to: "Open"
Ticket change [b2b4123c49] (rid 98384) by dkf on 2009-01-05 20:30:25:
- icomment:
problems now tracked in 2487771
- login: "dkf"
- mimetype: "text/plain"
- username: "dkf"
- icomment:
Ticket change [b7fdd10b5a] (rid 128892) by dkf on 2009-01-05 20:30:39:
- closedate changed to: "2009-01-05T13:30:39"
- closer changed to: "dkf"
- status changed to: "Closed"