Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] Built-in Code Formatter

Dear all,

I am new to the Eclispe CDT. Every thing looks very cool. The only
pity is that the Code Formatter does not seem to work. I was
suspecting if my Eclipse needs some more configuration to make it
work. However, judging from this email, it seems that the Code
Formatter is actually not implemented. Am I right? If this is the
case, can any one tell me how to set up Eclipse to use external
Formatter?

Thanks a lot!

Best regards,
Jingzhao

On 11/10/06, Leherbauer, Anton <Anton.Leherbauer@xxxxxxxxxxxxx> wrote:
Hi,

I have committed an initial version of a built-in C/C++ code formatter
(bug 95274).

Following predefined formatting profiles are available:
- K&R
- BSD/Allman
- GNU
- Whitesmiths
(See also http://en.wikipedia.org/wiki/Indent_style)

The output of the built-in formatter depends on the quality of the AST
that can be obtained from the source code. Although, some heuristic is
used to handle syntax errors and other parsing problems, the result may
be other than expected. It may also happen, that the formatter runs into
an unrecoverable problem and simply leaves the source code unmodified.

With the tracing option "org.eclipse.cdt.core/debug/formatter=true"
you can get more details in case of formatter problems.
The trace output would be esp. helpful when attached to a bug report.

Thanks,
Toni
_______________________________________________
cdt-dev mailing list
cdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/cdt-dev



Back to the top