Compiler Error C2275
'identifier' : illegal use of this type as an expression
An expression uses the ->
operator with a typedef
identifier.
The following sample generates C2275:
// C2275.cpp
typedef struct S {
int mem;
} *S_t;
void func1( int *parm );
void func2() {
func1( &S_t->mem ); // C2275, S_t is a typedef
}
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