<i>lrange with huge index, weird results</i> status still Open with 3 other changes
by
.
D 2017-11-03T10:42:01.424
J icomment First\sshot\sfor\sproposed\ssolution\sin\sbranch\s"bug-aaa02c55b9".\sFor\sTcl8\sI\swould\slike\sto\sclamp\sthe\svalues\sbetween\sINT_MIN\sand\sINT_MAX.\sI\sdon't\sthink\sthat's\stoo\sdangerous,\ssince\swe\scan\sallready\suse\sINT_MAX\sin\sscripts\sdirectly:\sWe\smust\salready\shandle\sthat,\sanywhere\swe\sare\sfailing\sto\sdo\sso\sis\sa\sbug.\r\n\r\nFor\sTcl9,\sI\swould\slike\sto\smodify\sthe\sAPI\s(which\sis\sjust\sinternal,\sso\sthat's\sOK)\sto\suse\s"size_t\s*"\sin\sstead\sof\s"int\s*".\sThen\swe\scan\sclamp\sbetween\s-1\s(represented\sas\s(size_t)-1)\sand\sLLONG_MAX\s(actually\s(size_t)-2),\swhich\sis\ssufficiently\sfor\sall\sfuture\smemory\slimitations.\s;-)\r\n\r\nTIP\sis\sin\spreparation\s(sofar\sonly\sin\smy\smind\syet\s...)
J login jan.nijtmans
J mimetype text/x-fossil-wiki
K aaa02c55b9cb7b62c39bb02a7631ccd88fd00295
U jan.nijtmans
Z b9257cf8905028a709d53e3882a70985