Export (0) Print
Expand All
Expand Minimize

Compiler Error C2232

Error Message

'–>' : left operand has 'class-key' type, use '.'

The operand to the left of the -> operator is not a pointer. Use the period (.) operator for a class, structure, or union.

The following sample generates C2232:

// C2232.c
struct X {
    int member;
} x, *px;
int main() {
    x->member = 0;   // C2232, x is not a pointer

    px->member = 0;
    x.member = 0;
}

Community Additions

ADD
Show:
© 2014 Microsoft