https://bugs.llvm.org/show_bug.cgi?id=46036

Richard Smith <[email protected]> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |INVALID

--- Comment #1 from Richard Smith <[email protected]> ---
Clang is correct; the friend declaration only lets you access protected members
of base classes when they're named as members of the befriending class. Within
ignored_friend_declaration_t it is valid to refer to test_child::value, but not
to test_base::value.

The C++ rules used to allow this kind of access, but were changed because it's
not implementable in general. See
http://www.open-std.org/jtc1/sc22/wg21/docs/cwg_defects.html#1873. I would
imagine the other implementations have not yet implemented the revised rule.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to