Skip to content
Tcl Source Code View Ticket
Login

View Ticket

foreach wraps around loop counter for large lists

Closed / Fixedf4d15772f1c4ede2d7206ae2553c697afb0f4824Created 4 years agoUpdated 4 years ago
Descriptionmarkdown2023-04-19 16:26:04

foreach loop counter wraps around

% set l [testbigdata list 0x100000001]; llength $l
4294967297
% set n 0
0
% foreach e $l {incr n}
% set n
1
Referenced by1
apnadkarni Ticket [f4d15772f1]: 5 changes [History diff]2023-04-19 16:27:06
apnadkarniplain2023-04-20 16:47:56
Fixed in [fbe4c73160]
Log in (anonymous is fine) to add a comment.