[cfe-dev] Clang tutorial

Simone Pellegrini spellegrini at dps.uibk.ac.at
Wed May 27 01:57:33 PDT 2009


Hello,
thanks for the example but this is what I am currently doing in my program.

The problem is that every time I include some header like stdio.h in my 
code I get this error from the parser:

Adding /home/spellegrini/shared/openmpi-1.3.2-gcc433/include
** Parsing file: bench/example.c **
initialize
In file included from bench/example.c:7:
/home/spellegrini/shared/llvm/lib/clang/1.0/include//stdarg.h:29:9: 
error: unknown type name '__builtin_va_list'

This was not happening with previous versions of CLANG, so what has been 
changed? What's the problem with this __builtin_va_list??
How can I make clang able to parse it without complaining?

cheers, Simone

Eli Friedman wrote:
> On Wed, May 20, 2009 at 12:41 AM, Simone Pellegrini
> <spellegrini at dps.uibk.ac.at> wrote:
>   
>> I guess the best option is to have a look to clang-cc.cpp but it's
>> rather huge, is there any stripped version?
>>     
>
> Here's a highly simplified version of clang-cc.cpp that contains the
> bare essentials to get things working.  It takes C code from stdin,
> and writes LLVM assembly to stdout.  Hopefully, it's a decent starting
> point.
>
> -Eli
>   




More information about the cfe-dev mailing list