ping?

On 12/05/14 16:57, Nathan Sidwell wrote:
This (proto) patch addresses bug 6037 http://llvm.org/bugs/show_bug.cgi?id=6037
A request for a class definition to warn about inaccessible direct base classes.
  I've  added a check in Sema::AttachBaseSpecifiers to iterate over the direct
base array looking for ambiguous conversions to the individual bases.  The
output is something like:

6037.cc:8:15: warning: direct base 'A' is inaccessible due to ambiguity:
     struct C -> struct B -> struct A
     struct C -> struct A
struct C : B, A {
               ^
which matches the form of error for an ambiguous base conversion itself.

This patch triggers on a pile of testcases, which I've not yet fixed, because
I'd like some feedback on this approach first -- is there perhaps a better way
to do this checking?

Also, as this is a warning, I presume there should be some way to disable it.
How is that achieved in the clang framework?  (I'm not sure if the now failing
tests should be fixed by disabling the warning, for instance).

nathan

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to