[PATCH] D62584: [OpenCL][PR42033] Deducing addr space with template parameter types

John McCall via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 15 15:53:39 PDT 2019

rjmccall added a comment.

In D62584#1585091 <https://reviews.llvm.org/D62584#1585091>, @Anastasia wrote:

> In D62584#1583340 <https://reviews.llvm.org/D62584#1583340>, @rjmccall wrote:
> > Oh, yes, it definitely can't be done to class types.  I suppose we should just forget about it.
> Ok, regarding address space qualifiers in template instantiation - is it still ok that we ignore them here in this patch?

I think ignoring them in templates rather than diagnosing is the right thing to do, since it means that reasonable things, e.g. template functions returning `T`, won't be erroneous if you instantiate `T = __global int` just like they wouldn't be with `T = const int`.



More information about the cfe-commits mailing list