1
C++11 simplifies tt(friend) declarations by adding
2
emi(extended friend) em(declarations)
3
hi(friend: extended declaration)
4
to the language. When a class is declared as a friend, then the
5
tt(class) keyword no longer has to be provided. E.g.,
7
class Friend; // declare a class
8
typedef Friend FriendType; // and a typedef for it
9
using FName = Friend; // and a using declaration
13
friend Friend; // FriendType and FNaem: also OK
16
In the pre-C++11 standards the friend declaration required an explicit
17
tt(class); e.g., tt(friend class Friend).
19
The explicit use of tt(class) remains required if the compiler hasn't seen
20
the friend's name yet. E.g.,
24
// friend Unseen; // fails to compile: Unseen unknown.
25
friend class Unseen; // OK
28
Section ref(TEMPFRIENDS) covers the use of extended friend declarations in