Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!swrinde!cs.utexas.edu!bcm!shell!shell!rjohnson From: rjohnson@shell.com (Roy Johnson) Newsgroups: comp.std.c Subject: Re: More Re: Function Argument Evaluation argument Message-ID: Date: 1 Apr 91 20:21:43 GMT References: <17936@crdgw1.crd.ge.com> <15607@smoke.brl.mil> <17983@crdgw1.crd.ge.com> <3547@inews.intel.com> Sender: usenet@shell.shell.com (USENET News System) Organization: Shell Development Company, Bellaire Research Center, Houston, TX Lines: 30 In-Reply-To: bhoughto@pima.intel.com's message of 29 Mar 91 06:13:49 GMT I understand that the comma operator is a sequence point. If we use the comma operator as a sequence point between evaluations: int v=1; printf("%d %d\n", (1, v), (1,v++)); This can print 1 1 or 2 1 if I understand it right, which I very well may not. Similarly, char *x="foo", *y="bar", *p; p=x; printf("%s %s\n", (1, (p=y)), (1, p)); can print foo bar or bar bar Do I win? 8^) -- ======= !{sun,psuvax1,bcm,rice,decwrl,cs.utexas.edu}!shell!rjohnson ======= Feel free to correct me, but don't preface your correction with "BZZT!" Roy Johnson, Shell Development Company