[cfe-dev] Who owns declarations?

Sebastian Redl sebastian.redl at getdesigned.at
Mon Dec 22 10:38:30 PST 2008


Douglas Gregor wrote:
> I suggest that the CXXCatchStmt own the VarDecl, and be responsible 
> for its destruction and serialization. This is how 
> CXXConditionalDeclExpr handles its VarDecl for declarations of 
> variables within the condition of an "if".
OK, thanks.

By the way, why does CXXConditionalDeclExpr derive from DeclRefExpr? 
That's counter-intuitive from several viewpoints.

Sebastian



More information about the cfe-dev mailing list