Compiler Error C2802
static member 'operator operator' has no formal parameters
An operator declared by a static
member function must have at least one parameter.
The following sample generates C2802:
// C2802.cpp
// compile with: /clr /c
ref class A {
static operator+ (); // C2802
static operator+ (A^, A^); // OK
};
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for