Path: utzoo!attcan!uunet!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!usc!apple!hercules!fernwood!lia!steve From: steve@lia (Stephen Williams) Newsgroups: comp.lang.c++ Subject: Re: More cfront -> ANSI C compiler problems Keywords: cfront ANSI Message-ID: <1990Jul22.235825.2983@lia> Date: 22 Jul 90 23:58:25 GMT References: <511@pete.abccam.abcl.co.uk> <1990Jul22.234908.2820@lia> Reply-To: steve@lia.com (Stephen Williams) Organization: Litton/Integrated Automation, Alameda, California Lines: 28 In article <1990Jul22.234908.2820@lia> steve@lia.com (Stephen Williams) writes: >I have encountered a similar problem while using cfront 2.0 >on a SUN sparc. My code involves a class that looks like >this: > struct pair { short a, b; }; > > class foo { > public: > foo(); > > private: > int x; > static pair y[]; > }; > >The code for "y" looks like: > > struct mangled_pair y[]; > >which the "C" compiler rejects, claiming "unknown size." I ran more tests. Found that g++ also rejects this. However, if I give "y" a dimension (i.e. "y[3]") g++ is happy. This is almost sensible, but the SUN compiler message is unchanged. I am beginning to get annoyed. --Steve Williams.