<div dir="ltr">Can the different compilers use the same ASTContext?<div>E.g. say a.cpp contains Foo::bar() and b.cpp contains Foo::bar2(); will the Foo type in the semantic DeclContext contain both foo and foo2 after parsing both files?</div>
<div><br></div><div>Could you please provide an example how to setup the parsers?</div><div><br></div><div>Many thanks,<br><br><div class="gmail_quote">On Thu, Apr 5, 2012 at 8:29 PM, Douglas Gregor <span dir="ltr"><<a href="mailto:dgregor@apple.com">dgregor@apple.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="im"><br>
On Apr 5, 2012, at 7:04 AM, Yaakov Davis <<a href="mailto:yaakov.davis@gmail.com">yaakov.davis@gmail.com</a>> wrote:<br>
<br>
> I have a program which is composed of multiple .h and .cpp files.<br>
> I tried adding all the .cpp files by calling createMainFileID multiple times, but got an exception saying that the main file has already been defined.<br>
><br>
<br>
</div>You need to parse different .cpp files with different instances of the compiler.<br>
<br>
        - Doug<br>
</blockquote></div><br></div></div>