Path: utzoo!attcan!uunet!sco!seanf From: seanf@sco.COM (Sean Fagan) Newsgroups: comp.lang.c Subject: Re: passing structures Message-ID: <8187@scolex.sco.COM> Date: 14 Oct 90 09:34:33 GMT References: <241@motto.UUCP> <1990Oct11.162737.11332@zoo.toronto.edu> Sender: news@sco.COM Reply-To: seanf (Sean Fagan) Organization: The Santa Cruz Operation, Inc. Lines: 18 In article <1990Oct11.162737.11332@zoo.toronto.edu> henry@zoo.toronto.edu (Henry Spencer) writes: >In article <241@motto.UUCP> andrew@motto.UUCP (Andrew Walduck) writes: >>result = add(a,{5,8}); >>But this isn't supported by ANSII! There's no way to pass a structure >>as a parameter! It should be do-able, the prototype exists, so the >>types can be punned appropriately...any idea why it wasn't? No prior-art? gcc already does this, although you need a typecast. So there's your prior-art. I, however, have never used it (other than verifying that it works, just now), and henry's suggestion works just as well. -- -----------------+ Sean Eric Fagan | "*Never* knock on Death's door: ring the bell and seanf@sco.COM | run away! Death hates that!" uunet!sco!seanf | -- Dr. Mike Stratford (Matt Frewer, "Doctor, Doctor") (408) 458-1422 | Any opinions expressed are my own, not my employers'.