This patch addresses the first half of PR5542; failure to promote CVR qualifiers on the element type to the array type when checking whether they are more (or less) cv-qualified than another type. ([basic.type.qualifier] p5, final sentence) I've done this by refactoring the logic which existed in the internals of template deduction to do this transformation into the ASTContext. I considered QualType and CanQual<T>, but neither seemed as good of a fit. It might be better to accept a CanQualType input instead of a QualType which we immediately assert is canonical, but that involved more changes to existing code, so I left it out. I'm also not sure that we can correctly return a CanQualType, and it seemed better to convert to QualType immediately in that case. There are a few more places we need to use this that I'm still isolating and writing test cases, but they can go in as follow-up submissions.
Thanks! -Chandler
pr5542a.patch
Description: Binary data
_______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
