[llvm-bugs] [Bug 48887] New: [C++4OpenCL] Missing OpenCL specific diagnostics in templates
via llvm-bugs
llvm-bugs at lists.llvm.org
Tue Jan 26 08:07:13 PST 2021
https://bugs.llvm.org/show_bug.cgi?id=48887
Bug ID: 48887
Summary: [C++4OpenCL] Missing OpenCL specific diagnostics in
templates
Product: clang
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: OpenCL
Assignee: unassignedclangbugs at nondot.org
Reporter: anastasia.stulova at arm.com
CC: anastasia.stulova at arm.com, llvm-bugs at lists.llvm.org
Clang fails to diagnose invalid cases inside the templates that appear after
template parameter substitution:
template<typename T>
void templ() {
T loc;
}
void foo(){
templ<image1d_t>();
templ<__local event_t>();
templ<__local sampler_t>();
templ<half>();
image1d_t img;
__local event_t e;
__local sampler_t s;
half h;
}
'
The diagnostic will appear correctly for 'foo' but no 'templ'. Even if after
the substitution they have identical invalid cases.
See: https://godbolt.org/z/jn8WT3
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20210126/c0b7b506/attachment.html>
More information about the llvm-bugs
mailing list