Opened 6 years ago

Closed 6 years ago

#777 closed proposed feature (wontfix)

continue in for-loops does not alter control variable

Reported by: ren Owned by: somebody
Priority: minor Milestone: 4-1-0 and higher
Component: dontKnow Version: 4-0-3
Keywords: Cc:

Description

Using continue in for-loops does not alter the control variable, which in my opinion it should. For example following loop never terminates because i is never incremented:

for (int i=1; i<=1; i++) {i; continue;}

Change History (2)

comment:1 Changed 6 years ago by hannes

continue is internally used for all loops in Singular - so this cannot be changed. The behavior is documented (http://www.singular.uni-kl.de/Manual/4-0-3/sing_429.htm, http://www.singular.uni-kl.de/Manual/4-0-3/sing_463.htm). Maybe we rename it to avoid the confusion with continue of C?

comment:2 Changed 6 years ago by hannes

Resolution: wontfix
Status: newclosed
Note: See TracTickets for help on using tickets.