martong accepted this revision.
martong added a comment.
This revision is now accepted and ready to land.

Thanks for the update. Nice Work!



================
Comment at: clang/test/Analysis/region-store.c:66
+  // expected-warning@+1 {{passing arguments to 'b' without a prototype is 
deprecated in all versions of C and is not supported in C2x}}
+  b(&buffer);
+}
----------------
steakhal wrote:
> NoQ wrote:
> > steakhal wrote:
> > > tomasz-kaminski-sonarsource wrote:
> > > > tomasz-kaminski-sonarsource wrote:
> > > > > I would like to see an example where the called function is 
> > > > > implicitly defined.
> > > > After rethinking it, I have not idea how to construct that example.
> > > I could not construct such an example.
> > > It seems like clang errors out for cases when an implicit declaration of 
> > > a call mismatches with the definition of that function.
> > > https://godbolt.org/z/rM9ajeTf7
> > Yeah, if you scroll really far to the right, you'll see that the first 
> > error is actually a warning auto-promoted to an error. So you can pass 
> > `-Wno-implicit-function-declaration` and it'll disappear. Not sure what to 
> > do with the other error though, it really does notice that the implicit 
> > definition conflicts with the later explicit definition. So, dunno.
> Yup, I should have been more clear on this. See the test, I'm also passing 
> the `-Wno-implicit-function-declaration` :)
> Maybe Shafik or Aaron knows some weird stuff about how to make it 'compile'. 
> WDYT?
Interestingly,  GCC trunk compiles it without errors, the warnings are there 
though.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D136162

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

Reply via email to