Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
illegal use of friend specifier on 'function'
Remarks
A destructor or constructor cannot be specified as a friend.
Example
The following example generates C2256:
// C2256.cpp
// compile with: /c
class C {
public:
friend ~C(); // C2256
~C(); // OK
};