<i>The "int" type registration should be restored.</i> status still Open with 4 other changes
by
.
D 2024-07-03T13:05:30.042
J icomment I\sam\srepeating\sa\scomment\sI\smade\son\sthe\score\slist,\sfor\sthe\srecord.\r\n\r\nThe\sPython\stkinter\smodule\scan\screate\san\sembedded\sTcl\sinterpreter\r\n(with\sthe\sTk\spackage\sloaded)\sand\sprovides\sthe\sability\sto\srun\sarbitrary\sTcl\r\ncommands\sin\sthe\sinterpreter.\s\sTherefore\s_tkinter.c\sneeds\sto\sbe\sable\sto\r\nconvert\sany\sTcl_Obj\sto\sa\sPython\sobject.\s\sIn\ssome\scases\sthat\sPython\sobject\r\nmay\sbe\sa\smostly\suseless\sobject\swhich\sjust\srecords\sthe\stype\sname\sof\sthe\sTcl_Obj\r\nbut\smost\sof\sthe\score\sTcl\sobject\stypes\shave\smeaningful\srepresentations\sas\r\nPython\sobjects.\s\sBelow\sis\sa\ssnippet\sfrom\sa\sPython\sinterpreter\ssession\sin\r\nwhich\sa\sTcl\sbignum\sis\sconverted\sto\sa\sPython\sint.\r\n\r\nAn\sinstance\sof\sthe\sPython\sclass\stkinter.Tk\sis\san\sencapsulation\sof\sa\sTcl\r\ninterpreter,\salthough\smany\stkinter\susers\sdon't\sknow\sthis\sand\sthink\sit\sis\r\nonly\sencapsulating\sthe\sroot\swindow.\s\sIt\shas\sa\scall\smethod\swhich\scan\sbe\sused\r\nto\srun\san\sarbitrary\sTcl\scommand.\r\n\r\n\s\s$\spython3\r\n\s\sPython\s3.11.8\s(v3.11.8:db85d51d3e,\sFeb\s\s6\s2024,\s18:02:37)\s[Clang\s13.0.0\s(clang-1300.0.29.30)]\son\sdarwin\r\n\s\sType\s"help",\s"copyright",\s"credits"\sor\s"license"\sfor\smore\sinformation.\r\n\s\s>>>\simport\stkinter\r\n\s\s>>>\sinterp\s=\stkinter.Tk()\r\n\s\s>>>\sx\s=\sinterp.call('expr',\s'11111111111111111111',\s'*',\s'22222222222222222222')\r\n\s\s>>>\sprint(x)\r\n\s\s246913580246913580241975308641975308642\r\n\s\s>>>\stype(x)\r\n\s\s<class\s'int'>\r\n\r\nWhile\sI\sdon't\sknow\sof\sany\suse\sfor,\ssay,\stclExprCodeType\sin\sPython,\sI\sthink\swe\r\nare\sproviding\sa\sgeneral\spurpose\stool\sand\swe\sshould\smake\sit\sas\suseful\sand\sas\r\ntransparent\sas\spossible\swithout\ssecond-guessing\show\sit\swill\sbe\sused\sin\sthe\r\nfuture.\s\sAnd,\sobviously,\sPython\sis\snot\sthe\sonly\sclient\sfor\ssuch\sa\stool.
J login marc_culler
J mimetype text/plain
J username Marc\sCuller
K b5bd08df8d61b4ea9bf0cc885f790b367c430a9f
U marc_culler
Z 3087bbf57015983632a3ae84fdf295af