[cfe-dev] using clang tools within a c program

Jacob Carlborg via cfe-dev cfe-dev at lists.llvm.org
Thu Sep 21 23:59:06 PDT 2017


On 2017-09-16 13:47, blubee blubeeme via cfe-dev wrote:
> Hello
> 
> I though that libclang was the C interface to clang but It seems that 
> libclang is all C++ and so I have to use C++ compiler and extern my c code?

No, libclang has a C interface. libclang and the whole compiler are 
implemented in C++ but it does provide a C interface [1].

[1] https://clang.llvm.org/doxygen/group__CINDEX.html

-- 
/Jacob Carlborg




More information about the cfe-dev mailing list