Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!rochester!kodak!ektools!randolph From: randolph@ektools.UUCP (Gary L. Randolph) Newsgroups: comp.lang.c Subject: Re: Pointer incrementation and assignme Message-ID: <1929@ektools.UUCP> Date: 2 Jun 89 12:36:45 GMT References: <2015@csuna.csun.edu> <236100012@mirror> Sender: randolph@ektools (Gary L. Randolph) Reply-To: randolph@ektools.UUCP (Gary L. Randolph) Organization: Eastman Kodak, Dept. 47, Rochester NY Lines: 28 In article <236100012@mirror> root@mirror.TMC.COM writes: -The compiler knows the size of the data that you are working with. -a+=1 and a = a+1 will still increment the pointer by 2. -The same way the compiler knows how to increment ints, floats, longs, -and doubles, it knows how to correctly increment any pointer, no matter -what the syntax that you use. -In reality What is 'reality' -the command a++ is just shorthand for a+=1 and a = a+1. It was origionally Things are never this simple at deeper levels. -made for lines like: - - whatchamacallit = whatchamacallit + 1; - -Carnigan and Ritchie were programmers who didn't like to type. ^^^^^^^^? I SERIOUSLY doubt that two brilliant minds (*Kerninghan* and Ritchie) included such a feature because they don't like to TYPE. Perhaps you are confusing this with the fact that 'type' was something the original C tended to ignore. There have been many pleas lately to keep the S/N ratio down. Let's not waste $$$$. (My past does not make me a saint :->) I recall, from my PDP 11 assembler days, two addressing modes; autoincrement and autodecrement. I believe that something of this nature had *much* more to do with the post and preincrement/decrement operators than did K&R's typing skills. Gary