Dumping template instantiation AST

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Dumping template instantiation AST

Sebastian Redl

Hi,

Still trying to track down a miscompile, I've now found the place where it
calls a default constructor instead of one with arguments. Now I'm trying
to dump the AST of that function, but it's a member template of a template
class, and the AST is full of unresolved expressions. I'm trying to find
the AST of the instantiation, but it appears that it isn't in the AST dump.

How do I get an AST dump for a template instantiation?

Sebastian

_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev
Reply | Threaded
Open this post in threaded view
|

Re: Dumping template instantiation AST

Douglas Gregor

On May 4, 2010, at 3:30 AM, Sebastian Redl wrote:

>
> Hi,
>
> Still trying to track down a miscompile, I've now found the place where it
> calls a default constructor instead of one with arguments. Now I'm trying
> to dump the AST of that function, but it's a member template of a template
> class, and the AST is full of unresolved expressions. I'm trying to find
> the AST of the instantiation, but it appears that it isn't in the AST dump.
>
> How do I get an AST dump for a template instantiation?

You can get the AST dump for a template instantiation from within a debugger (just call the appropriate Dump method), but there's no way to do it from the command-line.

        - Doug
_______________________________________________
cfe-dev mailing list
[hidden email]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-dev