Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Eclipse CDT shows wrongly errors
Eclipse CDT shows wrongly errors [message #724670] Mon, 12 September 2011 18:58 Go to next message
NMO  is currently offline NMO Friend
Messages: 9
Registered: June 2010
Junior Member
Hi,

I've created a C++ project that compiles fine and also runs without a problem. A few days ago I reinstalled my OpenSuse but kept my workspace to use it with my new installation. So after installation of OpenSuse I downloaded Eclipse and CDT and opened my already existing workspace. My C++ project again runs without a problem but the curious thing is that Eclipse shows bugs in my project although there are no bugs present. To be more precise Eclipse shows two types of bugs: "Type x could not be resolved" and "Invalid arguments Candidates are .."
Is that a bug of CDT?

Operating System: OpenSuse 11.4
Eclipse Indigo
CDT 8.0.0


Re: Eclipse CDT shows wrongly errors [message #724786 is a reply to message #724670] Tue, 13 September 2011 07:22 Go to previous messageGo to next message
Axel Mueller is currently offline Axel MuellerFriend
Messages: 1973
Registered: July 2009
Senior Member
These error messages are from the static code analyzer CODAN. I guess the index of your project is not correct due to the reinstallation (and CODAN relies on this index). Rebuild your index (Context menu of Project: Index->Rebuild).

Before you ask
- search this forum
- see the FAQ http://wiki.eclipse.org/CDT/User/FAQ
- google
Re: Eclipse CDT shows wrongly errors [message #725235 is a reply to message #724786] Wed, 14 September 2011 10:36 Go to previous messageGo to next message
NMO  is currently offline NMO Friend
Messages: 9
Registered: June 2010
Junior Member
Yes that solved it . Thank you!
Re: Eclipse CDT shows wrongly errors [message #735718 is a reply to message #725235] Wed, 12 October 2011 15:15 Go to previous messageGo to next message
Dmitry Egorov is currently offline Dmitry EgorovFriend
Messages: 11
Registered: July 2009
Location: Moscow
Junior Member
Hi, all!
I create the Linux Kernel Module project follow by this link:http://www.on5di.com/~noel/eclipse/kernelmodules.html
and have the same problems (Eclipse shows two types of bugs: "Type x could not be resolved" and "Invalid arguments Candidates are ..").
It not fixed by 'Index->Rebuild'
I create C and C++ projects, both has fake errors (my kernel module and exe file for testing produced correctly by make&gcc).
Appreciate any suggestions.

Operating System: Mageia 1
Eclipse Indigo
CDT 8.0.0
Thanks in advance.
Egorov Dmitry.

[Updated on: Wed, 12 October 2011 15:22]

Report message to a moderator

Re: Eclipse CDT shows wrongly errors [message #738524 is a reply to message #735718] Sun, 16 October 2011 10:48 Go to previous messageGo to next message
Nobody Mising name is currently offline Nobody Mising nameFriend
Messages: 75
Registered: July 2010
Member
Quote:

Eclipse shows two types of bugs: "Type x could not be resolved" and "Invalid arguments Candidates are .."


These messages are from Codan (static analysis) they are not related to compilation errors. Static analysis in CDT is far from perfect and produces false problems, so you can: ignore such false problems, turn off static analysis for project/particular files.
Re: Eclipse CDT shows wrongly errors [message #883594 is a reply to message #738524] Fri, 08 June 2012 22:00 Go to previous message
Angus Henderson is currently offline Angus HendersonFriend
Messages: 13
Registered: October 2011
Junior Member

I found two cases where I was getting incorrect CODAN errors.

1. if i use this syntax to declare a method:

void myfunc( myClass & classArg );

if i take out one of the spaces either side of the '&' errors go away

2. include files not found:

if CODAN says a reference in a headr file cannot be found, when it is found by
the compiler, i just include that header specifically in the offending file.

ANgus
Previous Topic:Get Toolchain selected on project wizard
Next Topic:parsers with a red Xs
Goto Forum:
  


Current Time: Fri Apr 19 15:21:11 GMT 2024

Powered by FUDForum. Page generated in 0.03394 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top