|
2009-12-29
| ||
| 21:56 | • Ticket [2895741fff] expr min and max don't work in a safe interp status ... artifact: d573b2e105 user: dkf | |
|
2009-12-10
| ||
| 02:46 | • Ticket [2895741fff]: 1 change artifact: 0c0aab3337 user: dgp | |
|
2009-11-11
| ||
| 22:40 | • Ticket [2895741fff]: 5 changes artifact: c55dd8777c user: dkf | |
| 22:33 | • Ticket [2895741fff]: 4 changes artifact: e4a9dd5f4b user: john13a | |
| 22:27 | • Ticket [2895741fff]: 4 changes artifact: dd5c545419 user: dgp | |
| 19:51 | • Ticket [2895741fff]: 1 change artifact: 33886c8f12 user: dkf | |
| 06:35 | • New ticket [2895741fff]. artifact: 9f063f5e51 user: john13a | |
expr min and max don't work in a safe interp
Open2895741fffffffffffffffffffffffffffffffffCreated 17 years agoUpdated 17 years ago
Descriptionplain2009-11-11 06:35:58
::tcl::mathfunc::min and ::tcl::mathfunc::max are not created in a safe interp this both commands are procs, written in pure tcl [info procs ::tcl::mathfunc::*] To avoid this, create aliases for this method, but I think, this soud be created as well (like sin and cos and so on)
dkf Ticket [2895741fff]: 1 change
[History diff]2009-11-11 19:51:38
dgpplain2009-11-11 22:27:01
This is a consequence of Tcl_Init() not being called on safe interps. I was surprised to see that. I'll want to restore my understanding of the history before leaping on this change, even though the requested end if clearly correct.
john13aplain2009-11-11 22:33:10
Of course. On the other hand even a safe interp can create this commands on his own. My suggest is to split Tcl_Init() into 2 or 3 parts, one for safe, one fore normal unsafe, and eventually a common init.
dkfplain2009-11-11 22:40:09
That's a bit complex because most of what Tcl_Init is doing is arranging for paths to be set correctly (very nasty!) and for init.tcl to be sourced (which does many things, including defining min() and max() of course).
dgp Ticket [2895741fff]: 1 change
[History diff]2009-12-10 02:46:46
dkfplain2009-12-29 21:56:55
Made both max() and min() work in safe interpreters. There's still the reconsideration of just what is to be done when building a safe interpreter, but that's now a less pressing problem so the priority is dropped a bit.
Log in (anonymous is fine) to add a comment.