Path: utzoo!telly!ddsw1!lll-winken!uunet!bu-cs!bloom-beacon!oberon!orion.cf.uci.edu!uci-ics!glacier.ics.uci.edu!schmidt From: schmidt@glacier.ics.uci.edu (Doug Schmidt) Newsgroups: gnu.g++.bug Subject: Re: g++-1.32.0 segmentation fault Message-ID: <3434@paris.ics.uci.edu> Date: 8 Jan 89 07:44:55 GMT References: <69@cs.columbia.edu> Sender: news@paris.ics.uci.edu Reply-To: Doug Schmidt Distribution: gnu Organization: University of California, Irvine - Dept of ICS Lines: 26 In article <69@cs.columbia.edu> fox@cs.columbia.edu (David Fox) writes: |> |>By the way, did anyone see my report about static objects in the scope |>of a function being constructed on each entry to the function? Is it |>real or is it me? Is it wrong or is it right? |> Well, I believe that you're not supposed to have static data objects for classes with destructors. Check out the recent discussion in comp.lang.c++ for details on why this is. Therefore, g++ is wrong not to complain about them at compile time. Here's the output from AT&T cfront for your program: ---------------------------------------- CC foo.C: "foo.C", line 25: sorry, not implemented: local static n of class with constructor 1 error ---------------------------------------- Doug -- schmidt@ics.uci.edu (ARPA) | Per me si va nella citta' dolente. office: (714) 856-4043 | Per me si va nell'eterno dolore. | Per me si va tra la perduta gente. | Lasciate ogni speranza o voi ch'entrate.