gnu.gcc.help
[Top] [All Lists]

Re: No default constructor in return statement allowed?

Subject: Re: No default constructor in return statement allowed?
From: Larry I Smith
Date: Tue, 27 Sep 2005 23:05:13 GMT
Newsgroups: gnu.gcc.help
anding@xxxxxxx wrote:
> Many thanks for your quick reply. I will try to upgrade to gcc 3.4.
> Kind regards
> Kai
> 

Or just remove the un-necessary extra parens in the return statement.

You see things like this a lot:

  return (1);
  return (f);
  return (a + b);
  return (Stuff());

'return' is not a function call.
The parens have never been required.  Just remove them
and your poblems should disappear:

  return 1;
  return f;
  return a + b;
  return Stuff();

Larry

<Prev in Thread] Current Thread [Next in Thread>