[LLVMbugs] [Bug 11515] New: incorrect access checking for friends of friends

bugzilla-daemon at llvm.org bugzilla-daemon at llvm.org
Thu Dec 8 18:45:46 PST 2011


             Bug #: 11515
           Summary: incorrect access checking for friends of friends
           Product: clang
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: enhancement
          Priority: P
         Component: C++
        AssignedTo: unassignedclangbugs at nondot.org
        ReportedBy: richard-llvm at metafoo.co.uk
                CC: dgregor at apple.com, llvmbugs at cs.uiuc.edu
    Classification: Unclassified

Clang allows this:

class A {
  int n;
  friend struct B;

struct B {
  friend int get(A &a) {
    return a.n;

It should not!

Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

More information about the llvm-bugs mailing list