Community
Participate
Working Groups
Create a simple Managed C Hello World program from the C Project Wizard templates. Build the project and open the hello.c source file. The EXIT_SUCCESS macro is marked in error by CODAN and the macro cannot be hovered over. An indexer freshen all files causes the marker to go away and the macro is known to the hover help. The freshen step should not be required.
This actually works for me: * The editor is opened automatically after creating the project and shows the errors. * When the indexer (which is triggered automatically) is done, the editor automatically starts the reconciler and the errors go away. Is my workflow different to yours? In your case, do the errors go away if you simply close the editor and open it again?
(In reply to comment #1) > This actually works for me: > * The editor is opened automatically after creating the project and shows the > errors. > * When the indexer (which is triggered automatically) is done, the editor > automatically starts the reconciler and the errors go away. > > Is my workflow different to yours? In your case, do the errors go away if you > simply close the editor and open it again? For me, the indexer doesn't get triggered automatically. I have to do so manually. I am using the C/C++ for Linuxtools EPP download. I am creating a regular C Managed Hello World Project (i.e. no Autotools). I select Executable->Hello World project and hit Finish. The source file shows up in the editor with the error and then I build the project via the Hammer icon. After the successful build, the editor still shows error. Closing and then reopening the source file has no effect. This is on a Fedora 15 system. I also tried installing the C/C++ SDK on the Juno M4 classic download. Same failure sequence.
Please use the tracing options: org.eclipse.cdt.core/debug/indexer/setup=true org.eclipse.cdt.core/debug/indexer/activity=true When I create a hello world project, it outputs: Indexer: Adding new project hw Indexer: Setup is postponed: hw Indexer: Setup is postponed: hw Indexer: Creation for project hw Indexer: PDOMImporter start Indexer: PDOMImporter completed, ok=false Indexer: Rebuiding for project hw Indexer: start PDOMRebuildTask Indexer: parsing \hw\src\hw.c ...
(In reply to comment #3) > Please use the tracing options: > org.eclipse.cdt.core/debug/indexer/setup=true > org.eclipse.cdt.core/debug/indexer/activity=true > > When I create a hello world project, it outputs: > Indexer: Adding new project hw > Indexer: Setup is postponed: hw > Indexer: Setup is postponed: hw > Indexer: Creation for project hw > Indexer: PDOMImporter start > Indexer: PDOMImporter completed, ok=false > Indexer: Rebuiding for project hw > Indexer: start PDOMRebuildTask > Indexer: parsing \hw\src\hw.c > ... Ok, the indexer is definitely running, but the error is still shown and isn't cleared. I tried closing the file in the editor and then re-opening. No change. The EXIT_SUCCESS macro should have been found in stdlib.h which it shows it is parsing. Application Started: 8818 Indexer: Adding new project hellotest Indexer: Setup is postponed: hellotest Indexer: Creation for project hellotest Indexer: PDOMImporter start Indexer: PDOMImporter completed, ok=false Indexer: Rebuiding for project hellotest Indexer: start PDOMRebuildTask Indexer: parsing /hellotest/src/hellotest.c Indexer: adding file:/usr/include/bits/wordsize.h Indexer: adding file:/usr/include/sys/cdefs.h Indexer: adding file:/usr/include/gnu/stubs-64.h Indexer: adding file:/usr/include/gnu/stubs.h Indexer: adding file:/usr/include/features.h Indexer: adding file:/usr/lib/gcc/x86_64-redhat-linux/4.6.1/include/stddef.h Indexer: adding file:/usr/include/bits/typesizes.h Indexer: adding file:/usr/include/bits/types.h Indexer: adding file:/usr/lib/gcc/x86_64-redhat-linux/4.6.1/include/stddef.h Indexer: adding file:/usr/include/wchar.h Indexer: adding file:/usr/include/_G_config.h Indexer: adding file:/usr/lib/gcc/x86_64-redhat-linux/4.6.1/include/stdarg.h Indexer: adding file:/usr/include/libio.h Indexer: adding file:/usr/include/bits/stdio_lim.h Indexer: adding file:/usr/include/bits/sys_errlist.h Indexer: adding file:/usr/include/stdio.h Indexer: adding file:/usr/lib/gcc/x86_64-redhat-linux/4.6.1/include/stddef.h Indexer: adding file:/usr/include/bits/waitflags.h Indexer: adding file:/usr/include/bits/endian.h Indexer: adding file:/usr/include/bits/byteswap.h Indexer: adding file:/usr/include/endian.h Indexer: adding file:/usr/include/bits/waitstatus.h Indexer: adding file:/usr/include/time.h Indexer: adding file:/usr/lib/gcc/x86_64-redhat-linux/4.6.1/include/stddef.h Indexer: adding file:/usr/include/bits/select.h Indexer: adding file:/usr/include/bits/sigset.h Indexer: adding file:/usr/include/time.h Indexer: adding file:/usr/include/bits/time.h Indexer: adding file:/usr/include/sys/select.h Indexer: adding file:/usr/include/sys/sysmacros.h Indexer: adding file:/usr/include/bits/pthreadtypes.h Indexer: adding file:/usr/include/sys/types.h Indexer: adding file:/usr/include/alloca.h Indexer: adding file:/usr/include/stdlib.h Indexer: adding file:/notnfs/jjohnstn/workspace-test-m4/hellotest/src/hellotest.c Indexer: completed PDOMRebuildTask[457ms] I then do "freshen all files" bash $ Indexer: start PDOMUpdateTask Indexer: parsing /hellotest/src/hellotest.c Indexer: adding file:/usr/include/stdio.h Indexer: adding file:/usr/include/bits/waitstatus.h Indexer: adding file:/usr/include/stdlib.h Indexer: adding file:/notnfs/jjohnstn/workspace-test-m4/hellotest/src/hellotest.c Indexer: completed PDOMUpdateTask[117ms] That clears the error. Any other options I should try? Is there a way to see what macros it knows about after the first pass?
It looks like some headers are missing. Do you have the gcc-c++ package (C++ support for GCC) ?
(In reply to comment #5) > It looks like some headers are missing. Do you have the gcc-c++ package (C++ > support for GCC) ? Never mind, just read it's a C project, not C++ :p
I tried with Fedora 15 and Juno M4 and I got the same error. Then I updated to the nightly build and it went away. https://hudson.eclipse.org/hudson/job/cdt-nightly/
Thanks Jeff and Mark-Andre, with your information I am 99% sure this is a duplicate of bug 367753. *** This bug has been marked as a duplicate of bug 367753 ***