Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [cdt-dev] LLVM Project Blog: A path forward for an LLVM toolchain on Windows

I have a tiny plugin (sorry not open source) that implements org.eclipse.cdt.core.CodeFormatter extension point and calls clang-format with -output-replacements-xml flag. The XML produced by clang-format is parsed, converted into an array of TextEdits, and returned from the format method.

Clang-format is fast because it doesn't do complete parsing of the code and therefore doesn't need to read included header files.

-sergey


On Mon, Sep 16, 2013 at 5:21 AM, scalpel4k <scalpel4k@xxxxxxxxx> wrote:

does that mean one can directly use/import a system-wide .clang-format file?

 

I think I don't quite understand what you mean with scanner-based formatting. Where do I find that? Is it the regular formatter?

 

thx Michi

 

On Sunday 15 Sep 2013 08:40:57 Sergey Prigogin wrote:

> We are using it with CDT. It does scanner-based formatting without building

> an AST. The quality is pretty good.

>

> -sergey

>

>

> On Sat, Sep 14, 2013 at 10:24 PM, scalpel4k <scalpel4k@xxxxxxxxx> wrote:

>

> > **

> >

> >

> >

> > On Wednesday 11 Sep 2013 16:49:24 Nathan Ridge wrote:

> >

> > > > There is no doubt LLVM is becoming a huge force. Though I'm more

> >

> > > interested in it from the parser/indexer side. I wonder how we'd plug it

> >

> > > in...

> >

> >

> >

> > have you seen clang-format for code formatting?

> >

> > http://clang.llvm.org/docs/ClangFormat.html

> >

> >

> >

> > _______________________________________________

> > cdt-dev mailing list

> > cdt-dev@xxxxxxxxxxx

> > https://dev.eclipse.org/mailman/listinfo/cdt-dev

> >

> >


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



Back to the top