[cfe-dev] FoldingSetVector and removing template specializations

Axel Naumann Axel.Naumann at cern.ch
Fri Jun 8 05:24:24 PDT 2012


Hi,

r156133 (introduction of FoldingSetVector for template specializations)
broke our use case: we need to be able to revert AST nodes, i.e. we rely
on RemoveNode(). RemoveNode() is evil, so I suggest the attached patch
that allows us to cast-to-derived the FoldingSetVector, where our evil
derived implements RemoveNode() without exposing it to clang.

Would you agree to that tiny change? (If so I'll reuse that pattern for
subsequent occurrences of this problem :-)

Cheers, Axel.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: clang_FoldingSetVector_protected_fields.diff
Type: text/x-patch
Size: 404 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20120608/68fd8937/attachment.bin>


More information about the cfe-dev mailing list