I know that llvm
can be used to convert c++ into c code. I was wondering if clang
could do the same thing (seeing as clang
was derived from llvm
).
So can I use clang
to convert c++ code into c code?
If you want to know why I want to do this here is my scenario:
PIC, which is a micro controller manufacturer, does not make c++ compilers, but does make c compilers for most of their products. I want to write in c++ and then as part of my build process, convert the c++ code into a temporary c file, which is then fed into the PIC compiler, and viola I have written c++ code for a PIC micro.