POV-Ray : Newsgroups : povray.off-topic : Coding in ___ is like ___ : Re: Coding in ___ is like ___ Server Time
4 Sep 2024 19:20:04 EDT (-0400)
  Re: Coding in ___ is like ___  
From: Warp
Date: 26 Feb 2010 07:37:48
Message: <4b87c09c@news.povray.org>
Darren New <dne### [at] sanrrcom> wrote:
> >   And it's not like gcc didn't have similar-sounding error messages:
> > error: ISO C++ forbids declaration of 'x' with no type

> I've gotten a few of those and not understood them, actually. I don't 
> remember what I had, but having something more along the lines of "you 
> forgot an #include" would be a better error message, I think. :-)

  You can get that one if you write eg. "static x;"

  It should be rather clear: You have defined a static variable named 'x',
but with no type. (In C it would default to int, but the C++ standard forbids
omitting the type, which is what the error message is saying.)

-- 
                                                          - Warp


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.