Anastasia added inline comments.

================
Comment at: test/SemaOpenCL/clang-builtin-version.cl:32
+  work_group_reserve_write_pipe(tmp, tmp); // expected-error{{implicit 
declaration of function 'work_group_reserve_write_pipe' is invalid in OpenCL}}
+  // expected-note@-1{{did you mean 'work_group_reserve_read_pipe'?}}
+  // expected-note@-2{{'work_group_reserve_write_pipe' declared here}}
----------------
Anastasia wrote:
> echuraev wrote:
> > Anastasia wrote:
> > > Why do we get this note now? I believe work_group_reserve_read_pipe 
> > > shouldn't be available either?
> > May be I don't understand something but I think that it is the right 
> > diagnostic message. We called work_group_reserve_read_pipe in line 29. So 
> > for this case we will get the following message: 
> > //clang-builtin-version.cl: 31 error: implicit declaration of function 
> > 'work_group_reserve_write_pipe' is invalid in OpenCL
> > clang-builtin-version.cl: 31 note: did you mean 
> > 'work_group_reserve_read_pipe'?
> > clang-builtin-version.cl: 29 note: 'work_group_reserve_read_pipe' declared 
> > here//
> But there is an error now given for the call to 
> 'work_group_reserve_read_pipe'. Why is it still added to the declarations? I 
> think we should prevent this.
Also do you know why we didn't have these notes before? I don't see anything 
related in your change.


https://reviews.llvm.org/D31745



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to