Path: utzoo!attcan!uunet!husc6!rutgers!apple!voder!wlbr!mh From: mh@wlbr.EATON.COM (Mike Hoegeman) Newsgroups: comp.lang.c Subject: Re: Portability of passing/operating on structures... Summary: it's not. Message-ID: <23933@wlbr.EATON.COM> Date: 16 Oct 88 19:02:32 GMT References: <8810111934.AA21941@ucbarpa.Berkeley.EDU> <8308@alice.UUCP> Reply-To: mh@wlbr.eaton.com.UUCP (Mike Hoegeman) Organization: Eaton IMSD, Westlake Village, CA Lines: 25 In article <8308@alice.UUCP> ark@alice.UUCP (Andrew Koenig) writes: >In article <8810111934.AA21941@ucbarpa.Berkeley.EDU>, U23405@UICVM.Berkeley.EDU (Michael J. Steiner) writes: >> Is it considered portable to do the following things with >> structures or unions? >> -pass them (by value) to functions >Yes. No >> -have functions which return them >Yes. No >> -assign them (=) >Yes. No I've worked on alot of machines where you cannot do ANY of the above. Maybe that's not "right". Maybe one should boycott such compilers. Any way you look at it though it's still not portable. I would avoid passing structures by value until more compilers allow this. Right now there are too many that don't.