[cfe-dev] problem with clang application

Nobin Mathew nobin.mathew at gmail.com
Mon Jun 21 21:36:25 PDT 2010


On Tue, Jun 22, 2010 at 7:34 AM, Douglas Gregor <dgregor at apple.com> wrote:
>
> On Jun 19, 2010, at 7:25 AM, Nobin Mathew wrote:
>
>> Is there any problem in this code fragment
>>
>>     scope.sm.createMainFileID(File, SourceLocation());
>>       scope.pp->EnterMainSourceFile();
>>       IdentifierTable identitab(scope.lang);
>>       MinimalAction action(*(scope.pp));
>>       Parser parse(*(scope.pp), action);
>>       parse.ParseTranslationUnit();
>>       identitab.PrintStats();
>>
>> I am not able to find the problem in the library, any help?
>
> I highlight recommend using CompilerInvocation/CompilerInstance rather than trying to set up all of the various interconnected pieces.

Thanks, I also came to the same conclusion after going through cc1_main().

>
>        - Doug
>
>




More information about the cfe-dev mailing list