Unix/Java design issues (Was: Re: Is CDATA "structure"?)

Hennessy, Sean shennessy at devcor.com
Tue Jul 27 01:06:24 BST 1999

John Cowan wrote:
The basic problem is code like this:

	unsigned count;
	while (--count > 0) {
		/* do something */

This loop will never fail, because unsigned numbers are always greater
than or equal to zero. 

Sean says:
unsigned numbers are not negative!
unsigned count will eventually reach zero and exit the while loop.

Those short on patience or machines with 32bit integral types
should initialize count = 10; or less and see for themselves..

xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev at ic.ac.uk
Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ and on CD-ROM/ISBN 981-02-3594-1
To (un)subscribe, mailto:majordomo at ic.ac.uk the following message;
(un)subscribe xml-dev
To subscribe to the digests, mailto:majordomo at ic.ac.uk the following message;
subscribe xml-dev-digest
List coordinator, Henry Rzepa (mailto:rzepa at ic.ac.uk)

More information about the Xml-dev mailing list