[cfe-commits] [PATCH (need approval)] Add instantiations of out-of-line member variable declarations to DeclContext

Douglas Gregor dgregor at apple.com
Tue Jul 6 11:25:15 PDT 2010


On Jul 4, 2010, at 7:02 AM, Peter Collingbourne wrote:

> Currently instantiations of out-of-line member variable declarations
> are created and added to the redeclaration list but are not added to
> any DeclContext.  This is a problem for any traversal of the AST which
> depends on seeing identical sets of AST nodes via the redeclaration
> lists and via DeclContexts.

The current behavior is actually intentional. Template instantiations aren't meant to show up in a normal AST traversal (e.g., in decls_begin()/decls_end() when iterating over a DeclContext) because they weren't written in the source. For what kind of application is this behavior causing a problem?

	- Doug



More information about the cfe-commits mailing list