[PATCH] D52292: [Sema][OpenCL] Improve diagnostics for not viable overloadable function candidates
Dmitry Sidorov via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Thu Sep 20 05:32:56 PDT 2018
sidorovd added inline comments.
================
Comment at: include/clang/Sema/Sema.h:8576
+
+ /// Find and extension in an extension map and return its name
+ template<typename T, typename MapT>
----------------
Anastasia wrote:
> and extension -> an extension ?
Thanks!
================
Comment at: lib/Sema/Sema.cpp:1856
+std::string Sema::getOpenCLExtensionsFromDeclExtMap(FunctionDecl *FD) {
+ if (!OpenCLDeclExtMap.empty())
----------------
Anastasia wrote:
> Is this function to be used for both `OpenCLDeclExtMap` and `OpenCLTypeExtMap`? If yes, may be we could give it more generic name like 'getOpenCLExtensionsFromExtMap'...
No, this exact function is only for 'OpenCLDeclExtMap', for the type map one should implement a new function 'getOpenCLExtensionsFromTypeExtMap'. Actually I have done this for https://reviews.llvm.org/D51341 to make the patch more generic, but since I'm not sure if it ever came to light I can add it here unused.
https://reviews.llvm.org/D52292
More information about the cfe-commits
mailing list