Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 31 Jan 1999 17:47:08 +1000 (EST)
From:      Andrew Kenneth Milton <akm@zeus.theinternet.com.au>
To:        malartre@aei.ca (Malartre)
Cc:        hackers@FreeBSD.ORG
Subject:   Re: some weird C
Message-ID:  <199901310747.RAA27181@zeus.theinternet.com.au>
In-Reply-To: <36B407F7.1617E743@aei.ca> from Malartre at "Jan 31, 99 02:36:23 am"

next in thread | previous in thread | raw e-mail | index | archive | help
+----[ Malartre ]---------------------------------------------
| 
| I was expecting 9, not 10.
| since 4+5=9?

x is pre-incremented, making it 5 *before* the += takes effect.

This is correct behaviour.

-- 
Totally Holistic Enterprises Internet|  P:+61 7 3870 0066   |  Andrew
The Internet (Aust) Pty Ltd          |  F:+61 7 3870 4477   |  Milton
ACN: 082 081 472                     |  M:+61 416 022 411   |72 Col .Sig
PO Box 837 Indooroopilly QLD 4068    |akm@theinternet.com.au|Specialist

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199901310747.RAA27181>