Complete.Org: Mailing Lists: Archives: freeciv-dev: January 2004:
[Freeciv-Dev] Re: (PR#7075) break and continue in iterators
Home

[Freeciv-Dev] Re: (PR#7075) break and continue in iterators

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: undisclosed-recipients: ;
Subject: [Freeciv-Dev] Re: (PR#7075) break and continue in iterators
From: "Arnstein Lindgard" <a-l@xxxxxxx>
Date: Sat, 3 Jan 2004 08:03:41 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=7075 >

"break" inside iterate_outward{} doesn't work. Maybe not surprising
since the macro uses a for() loop inside a while() loop. Sometimes
"break" has the effect of a "continue", and that took a deliberate
effort to detect. This can easily become hard to find bugs for the
unwary.

If "goto" is perfectly valid C, less ambigous and equally well
defined as "break", then what exactly are the reasons for
discouraging it's use?


Arnstein




[Prev in Thread] Current Thread [Next in Thread]