[PATCH] D54858: [OpenCL] Improve diagnostics for address spaces in template instantiation

John McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 26 11:17:11 PST 2018


rjmccall added inline comments.


================
Comment at: lib/Sema/TreeTransform.h:4241
+  if (SemaRef.getLangOpts().OpenCL && T.getType()->isTemplateTypeParmType())
+    Quals.removeAddressSpace();
+
----------------
When do you actually add the qualifier back?

Also, I don't think this is specific to either OpenCL or direct references to template type parameters; it has to be any dependent type.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D54858/new/

https://reviews.llvm.org/D54858





More information about the cfe-commits mailing list