Path: utzoo!utgpu!news-server.csri.toronto.edu!bonnie.concordia.ca!nstn.ns.ca!news.cs.indiana.edu!samsung!usc!rpi!crdgw1!camelback!volpe From: volpe@camelback.crd.ge.com (Christopher R Volpe) Newsgroups: comp.lang.c Subject: Re: difference between c++; and ++c; Message-ID: <18391@crdgw1.crd.ge.com> Date: 10 Apr 91 12:01:02 GMT References: <1991Apr08.161444.10025@cs.ruu.nl> <2880223615@ARTEMIS.cam.nist.gov> Sender: news@crdgw1.crd.ge.com Reply-To: volpe@camelback.crd.ge.com (Christopher R Volpe) Lines: 20 In article <2880223615@ARTEMIS.cam.nist.gov>, miller@GEM.cam.nist.gov (Bruce R. Miller) writes: |> |>In article <1991Apr08.161444.10025@cs.ruu.nl>, Ernst de Ridder writes: |>> I once read (I'm not sure where, but I believe it was in the C++ |>> programming language) that some C-programmers argue that ++c is neater |>> than c++. (In situations where the side-effect doesn't matter). So |> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ |>If the side-effect doesn't matter, I prefer to use this: |> |>(ie. whitespace). Most compilers do a good job of optimizing it. :>> If the side effect doesn't matter and the value *does* matter, you're better off using "c + 1". Granted, it doesn't optimize into nothing quite as easily, but it does produce more accurate results. :-) :-) ================== Chris Volpe G.E. Corporate R&D volpecr@crd.ge.com