Skip to content
Tcl Source Code Artifact [602e0a6266]
Login

Artifact [602e0a6266]

Artifact 602e0a6266a4bb2f9077275f23eedcc7aff8215d14842ba9d6b4ae9f6a6aadee:

Ticket change [602e0a6266] - Ticket [28cc67a606a7ab77|28cc67a606] <i>array set from dict: set values multi times on the same array is slower with Tcl9.0.</i> status still Open with 3 other changes by sebres on 2024-04-16 20:27:31.
D 2024-04-16T20:27:31.992
J icomment >\sThe\scase\sis\salso\spresent\sif\sSimplePERM\sproc\sreturns\san\sarray.\r\n\r\nIt\sdoesn't\s"return\san\sarray",\sbecause\sit\sis\scurrently\simpossible\sin\stcl\s-\s[array\sget]\sreturns\sa\sdict:\r\n\r\n```\r\n\s\s\s%\stcl::unsupported::representation\s[array\sget\senv]\r\n\s\s\svalue\sis\sa\sdict\swith\sa\srefcount\sof\s1,\s...,\sno\sstring\srepresentation\r\n```\r\nTcl\scannot\s(and\sprobably\snever\swill)\sdirectly\sreturn\san\sarray\s-\sarray\sis\sjust\sa\scomplex\svariable\s(hash\stable\sin\svar\sin\sscope/NS/whatever),\sso\s[array\sget]\sgenerates\sa\sdict\sat\sthe\stime\sof\sexecution\sto\sbe\sable\sto\sreturn\sit\s(basically\sfor\sthe\ssame\sreason\swhy\sone\scannot\sreturn\sdirectly\s$env\s(that's\sas\simplemented\sin\score-tcl,\sthere\sare\sanother\stcl-engines\swhich\sable\sto\sdo\sthat\sand\seven\ssuch\swhere\sarray\sand\sdict\sare\sthe\ssame\sstuff).
J login sebres
J mimetype text/x-markdown
K 28cc67a606a7ab771af4c7b542b34ec1a377edc7
U sebres
Z 70ccb2deab098d023f6884a48e0dd89c