Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » Preprocessor directives & documentation Generator?
Preprocessor directives & documentation Generator? [message #201468] Wed, 12 September 2007 22:36 Go to next message
Eclipse UserFriend
Originally posted by: tlazaro18.gmail.com

Hi,

I'm working with CDT4.0 in Eclipse 3.3 Europe in a C project. Actually
it's a Dynamic C proyect for the Rabbit Semiconductor
(www.rabbitsemiconductor.com) wich behaves pretty much like C. I managed
to add an external .exe builder and make it work almost like Dynamic C
officil IDE but with a few issues.

The fore mentioned C variant comes with a set of compiler directives
like #use, #ximport, #xmem, etc. The content assistant highlights those
like if they were wrong. Is there a way of adding this directives?

I also have another problem with documentation. I usually have function
declared as follows (actually not so tightly packed):

/* START FUNCTION DESCRIPTION *************************
funcName
SYNTAX: void funcName();
DESCRIPTION:
PARAMETER:
RETURN VALUE:
USAGE:
KEY WORDS:
SEE ALSO:
END DESCRIPTION *********************************************************/
#memmap xmem
#nodebug
void funcName();

Since the Hovering option sees de #memmap xmem and #nodebug it doesn't
show the above documentation. I can move them above the commented area
to solve it but throughout the standard libraries this is the way they
are written. Is there a way to modifiy the understanding of how
documentations are defined so it can show what I want?

I would also like to know if there is a way/tool to generate an external
documentation, like you would usally do with Javadoc. This would be
awesome and it would also make less important my other problem with
documentation.

Thanks
Re: Preprocessor directives & documentation Generator? [message #201475 is a reply to message #201468] Thu, 13 September 2007 04:18 Go to previous messageGo to next message
Scott Gifford is currently offline Scott GiffordFriend
Messages: 7
Registered: July 2009
Junior Member
Tomas Lazaro <tlazaro18@gmail.com> writes:

[...]

> I would also like to know if there is a way/tool to generate an
> external documentation, like you would usally do with Javadoc. This
> would be awesome and it would also make less important my other
> problem with documentation.

Not sure about your other questions, but we have had good luck with
Doxygen for generating documentation:

http://www.doxygen.org/

We have a make target to build it, and we just build that target from
Eclipse to generate the documentation.

----Scott.
Re: Preprocessor directives & documentation Generator? [message #201487 is a reply to message #201468] Thu, 13 September 2007 07:14 Go to previous messageGo to next message
Anton Leherbauer is currently offline Anton LeherbauerFriend
Messages: 490
Registered: July 2009
Senior Member
Tomas Lazaro wrote:
> Hi,
>
> I'm working with CDT4.0 in Eclipse 3.3 Europe in a C project. Actually
> it's a Dynamic C proyect for the Rabbit Semiconductor
> (www.rabbitsemiconductor.com) wich behaves pretty much like C. I managed
> to add an external .exe builder and make it work almost like Dynamic C
> officil IDE but with a few issues.
>
> The fore mentioned C variant comes with a set of compiler directives
> like #use, #ximport, #xmem, etc. The content assistant highlights those
> like if they were wrong. Is there a way of adding this directives?

The way to go is to define a new language variant. See the extension
point 'org.eclipse.cdt.core.language'. You will need to do some
Java coding to add the additional preprocessor directives to your language.

> I also have another problem with documentation. I usually have function
> declared as follows (actually not so tightly packed):
>
> /* START FUNCTION DESCRIPTION *************************
> funcName
> SYNTAX: void funcName();
> DESCRIPTION:
> PARAMETER:
> RETURN VALUE:
> USAGE:
> KEY WORDS:
> SEE ALSO:
> END DESCRIPTION *********************************************************/
> #memmap xmem
> #nodebug
> void funcName();
>
> Since the Hovering option sees de #memmap xmem and #nodebug it doesn't
> show the above documentation. I can move them above the commented area
> to solve it but throughout the standard libraries this is the way they
> are written. Is there a way to modifiy the understanding of how
> documentations are defined so it can show what I want?

You could write your own hover based on the existing one and register it
under the extension point 'org.eclipse.cdt.ui.textHovers'.
Another way to go is to create a bugzilla enhancement request at
https://bugs.eclipse.org/bugs/enter_bug.cgi?product=CDT

> I would also like to know if there is a way/tool to generate an external
> documentation, like you would usally do with Javadoc. This would be
> awesome and it would also make less important my other problem with
> documentation.

I know of Doxygen and CppDoc, but I don't know if there are nice
integrations with Eclipse/CDT.

HTH
--
Anton Leherbauer
Wind River CDT Team, Austria
Re: Preprocessor directives & documentation Generator? [message #201573 is a reply to message #201487] Thu, 13 September 2007 17:31 Go to previous message
Eclipse UserFriend
Originally posted by: tlazaro18.gmail.com

Thanks to Anton and Scott! I chose Eclipse since I'm used to it by
working with Java so I beleive I can do the coding. I'm going to check
the doc generators. I'll get started right away. I'll let you know how
it works out just in case someone is having similar issues.


Thanks again!

Tomás
Previous Topic:Eclipse JEE and CDT
Next Topic:C++ testing framework
Goto Forum:
  


Current Time: Sun Jun 30 13:25:02 GMT 2024

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

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

Back to the top