Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!elroy.jpl.nasa.gov!zardoz.cpd.com!dhw68k!genisco!arcturus!berryc From: berryc@arcturus.uucp (Craig D. Berry (x1710)) Newsgroups: comp.lang.c++ Subject: Is this a bug? Message-ID: <1991Mar25.181029.28684@arcturus.uucp> Date: 25 Mar 91 18:10:29 GMT Distribution: na Organization: Rockwell International Lines: 24 I have a class with a static member function: class foo { ... public: static foo barfunc(); // Returns value of a foo object. ... } Now, somewhere else, I try to use barfunc to initialize a foo: foo quux = foo::barfunc(); This doesn't work; the compiler wants a ( after foo::, for reasons entirely mysterious to me. Could be expecting one of foo's constructors, I suppose... However, foo quux = (foo::barfunc()); works as intended; quux is created with the value returned by barfunc. Am I missing something, or is my compiler (Turbo C++ 1.0) broken?